A solid body will float in a liquid if its density is less than that of the liquid.
Density is the measure of how much mass is packed into a certain volume. When a solid object is placed in a liquid, it will either float or sink depending on the relative densities of the object and the liquid.
If the object has a higher density than the liquid, it will sink because it has more mass packed into the same volume as the liquid. However, if the object has a lower density than the liquid, it will float because it has less mass packed into the same volume as the liquid.
Therefore, for a solid body to float in a liquid, its density must be less than that of the liquid.