In this paper, the influence of Mo capping layer on magnetic anisotropy of MgO/CoFeB/Mo with varying thickness is studied. It is found that Mo capping layer shows more saturated magnetic moments than Ta capping layer. The direction of the external magnetic field has a great influence on the magnetic anisotropy. The MgO/CoFeB/Mo sample prepared in an applied magnetic field parallel to the plane shows in-plane magnetic anisotropy (IMA). IMA becomes weak as the CoFeB thickness decreases, and it still exists when the thickness decreases to 1.1 nm. At the same time, the saturation field vertical to the plane decreases. When the thickness of CoFeB layer decreases to 0.9 nm or less, the IMA disappears. In our study, the saturated magnetization and magnetic dead layer are 1600 emu/cm3 and 0.26 nm at the annealing temperature 200 ℃, and the interface anisotropy is 0.91 erg/cm2, which is smaller than previous research results. Increasing the annealing temperature helps the sample keep the saturated state under a small magnetic field vertical to the plane, and makes IMA weak and transform into PMA. The variation of the Mo capping layer thickness affects the saturation magnetic moment of the sample. The magnetic moment shows a sharp downtrend when the Mo layer is between 1.2 and 1.6 nm, then it turns stabler with Mo capping layer thickening. Meanwhile, when the Mo capping layer is 1.6 nm, the external vertical saturation field becomes smallest. However under the parallel magnetic field, changing the thickness or annealing temperature, or changing both leads to no PMA occurring. When the magnetic field direction changes from parallel to vertical direction, some of the samples show PMA after the annealing process. The magnetic anisotropy of MgO/CoFeB/Mo varies with the thickness of Mo capping layer. IMA is present when the Mo capping layer is 1 nm or less while PMA is present when the Mo capping layer is between 1.2 and 5 nm. The sample coercive force in the vertical direction varies with thickness, and its magnetic hysteresis loss is much larger when the thickness of Mo capping layer is 1.4 nm.