Magnesium oxide, or magnesia, is a white solid mineral, made of one part magnesium and one part oxygen. Its chemical formula is MgO. Magnesium oxide is used by libraries to make books last longer. It is also used as an insulator for some electrical wires, and to help crucibles resist high temperatures. Magnesium oxide is also used to treat heartburn and upset stomachs.