A lot of experimental and theoretical results have been published concerning terrestrial gravity compensation through magnetic forces on diamagnetic and paramagnetic fluids, such are hydrogen or oxygen. It is necesary to use a magnet with high enough field and "field gradient". Superconducting coils are frequently used for low susceptibility fluids. See references in MST (Microgravity Science and Technology), Nature, Phys Rev, JAP (Journal of Applied Physics), IEEE Transactions, Cryogenics, for example.
It has been shown that perfect compensation is not possible in any point of a 3D domain, but for particular points, or in any point of surfaces or straight lines, or in any point of circular lines. Outside of the line or surface of perfect compensation, microgravity is observed with an amount of error that can be calculated.