In this article, a numerical study of convective transport in a magnetic nanofluid (MNF) subject to an applied magnetic field has been carried out using the local thermal nonequilibrium (LTNE) model. A two-phase model consisting of the effect of Brownian motion, thermophoresis, and magnetophoresis is considered. The temperature within the fluid phase is assumed to be different from the temperature within the particle solid phase. The Chebyshev pseudospectral method is used to solve the eigenvalue problem for small-amplitude perturbation. The present study focuses on two different environments: (i) gravity environment and (ii) microgravity environment. In both environments, the results are derived for water-based and ester-based magnetic nanofluids (MNFs). The effect of various important parameters such as thermal diffusivity ratio is an element of, interphase heat transfer N-H, thermal capacity ratio gamma, the modified diffusivity ratio N-A, concentration Rayleigh number R-n, Lewis number Le, the Langevin parameter proportional to(L), and the nonlinearity of magnetization M-3 is observed at the onset of MNF convection for free-free boundaries. The value of the critical thermal Rayleigh number Ra-c and the critical magnetic Rayleigh number N-gc decreases as the values of N-H, gamma, N-A, R-n, Le, and M-3 increase, whereas, the values of both Ra-c and N-g, increase as the value of is an element of increases. The system is found to be more stable for ester-based MNFs as compared to water-based MNFs in both gravity and micro gravity environment.