The buoyant force

A fluid pushes up on a submerged object more at its bottom than at its top, and the net upward push equals the weight of the fluid it displaces, so an object floats when it is less dense than the fluid.

From AP Physics 1.