The investigation conducted in this paper aims to study free vibration and buckling behaviors of size-dependent functionally graded sandwich nanobeams. In order to take into account the small size effects, nonlocal elasticity theory of Eringen's is incorporated. Material properties of the functionally graded sandwich beams are supposed to change continuously through the thickness direction according to two forms of the volume fraction of constituents by power law functionally graded material and sigmoid law functionally graded material. These rules are modified to consider the effect of porosity, which covers four kinds of porosity distributions. Two types of sandwich nanobeams were provided: (a) homogeneous core and functionally graded skins and (b) functionally graded core and homogeneous skins. Third-order shear deformation theory without any shear correction factor in conjunction with Hamilton's principle is used to extract the governing equations of motions of porous functionally graded sandwich nanobeams and then solved analytically for two hinged ends. The effects of nonlocal parameter, length to thickness ratios, material graduation index, amount of porosity, porosity distribution shape, on the nondimensional frequency and critical buckling load of the functionally graded sandwich nanobeams made of porous materials are exhibited by a parametric study.