Magnesium chloride is an inorganic compound with the formula MgCl2 and its various hydrates. Anhydrous MgCl2 contains 25.5% elemental magnesium by mass. The hydrated magnesium chloride can be extracted from brine or sea water. As the natural mineral bischofite it is extracted (by solution mining) out of ancient seabeds, for example, the Zechstein seabed in northwest Europe. Anhydrous magnesium chloride is the principal precursor to magnesium metal. Hydrated magnesium chloride is the form most readily available.