This paper deals with the analytical and numerical studies of elastic buckling of a three-layered beam with metal foam core. Mechanical properties of the core are variable along the z-axis. There are two schemes of displacement of the faces and core of the beam: a broken line hypothesis and a non-linear hypothesis. The mathematical models for both types of displacements are presented. The governing differential equations of the sandwich beam are derived. Numerical analysis of sandwich beams is conducted in ANSYS environment. The finite elements analysis has been performed using a linear elastic buckling model. The analysis with constant and variable Young׳s modulus of the core of the beam is carried out. The values of the critical load obtained by the analytical and numerical (FEM) methods are compared.