Hydrogen gas (H2) is always produced when a metal reacts with water. This reaction is known as a metal-water reaction or hydrolysis of metals. The metal atoms in the metal lose electrons to the hydrogen atoms in the water molecules, forming metal ions and hydrogen gas. The reactivity of metals with water varies depending on the position of the metal in the periodic table. Alkali metals (Group 1) and alkaline earth metals (Group 2) react vigorously with water at room temperature, producing metal hydroxides and hydrogen gas. Transition metals generally react less vigorously with water, and some, such as iron and aluminum, form a protective oxide layer that inhibits further reaction.