The present work focuses on the analytical study of thermoelastic damping (TED) and frequency shift (FS) in micro-scale beams and TED in nano-scale beams. The considered thermoelastic beam is homogeneous, isotropic, and consists of sandiness and voids (TESV). TED and FS of the beam are studied under four types of distinct boundary conditions, viz. clamped-clamped (CC), simply supported-simply supported (SS), Cantilever, and clamped-simply supported (CSS), considering different types of practical engineering applications. Newton–Raphson method is used to numerically evaluate the first two eigenvalues of each type of beam. The expressions of the characteristic roots are also provided. Based on the linear Euler–Bernoulli theory, the closed-form expressions for the beams’ transverse vibrations are derived. Analytical expressions for the deflection, change in temperature, and void volume fraction are also obtained, followed by TED and FS analysis for the considered boundaries. Three theories of thermoelasticity, viz. the Classical dynamical coupled (CL), Lord–Shulman (LS), and Green–Lindsay (GL) thermoelasticity theories are considered in this problem. The influences of thermal relaxation times owing to the three thermoelasticity theories, voids, sandiness, micro & nano dimensions of the beam, and the first two modes (M1 & M2) on the TED and FS are illustrated graphically. Critical thickness (CrTh) and critical length (CrLt) of all four beams under the influence of the existing parameters are meticulously analyzed. Some special cases of this problem are discussed, and the obtained outcomes are validated with well-established results found in the extant literature. In-depth analysis of the effects of thermoelastic coupling and other existing parameters on the natural frequency of micro-/nano-scale resonators, among other applications, is quintessential for designing and optimizing frequency-sensitive nanoelectromechanical systems (NEMS) and microelectromechanical systems (MEMS). Hence, the present analysis may have significant application and contribution in areas utilizing NEMS/MEMS devices.