  We derive a free energy for weakly anisotropic ferromagnets which is valid in
the whole temperature range and interpolates between the micromagnetic energy
at zero temperature and the Landau free energy near the Curie point T_c. This
free energy takes into account the change of the magnetization length due to
thermal effects, in particular, in the inhomogeneous states. As an
illustration, we study the thermal effect on the Stoner-Wohlfarth curve and
hysteresis loop of a ferromagnetic nanoparticle assuming that it is in a
single-domain state. Within this model, the saddle point of the particle's free
energy, as well as the metastability boundary, are due to the change in the
magnetization length sufficiently close to T_c, as opposed to the usual
homogeneous rotation process at lower temperatures.
