Is sodium chloride an ionic compound?
When an element composed of atoms that readily lose electrons (a metal) reacts with an element composed of atoms that readily gain electrons (a non-metal), a transfer of electrons usually occurs, producing ions. The compound formed by this transfer stabilizes by the electrostatic attractions (ionic bonds) between the ions of opposite charge present in the compound. For example, when each sodium atom in a sample of sodium metal (group1) gives up one electron to form a sodium cation, Na+, and each chlorine atom in a sample of chlorine gas (group 17) accepts one electron to form a chloride anion, Cl−, the resulting compound, NaCl, is composed of sodium ions and chloride ions in the ratio of one Na+ ion for each Cl− ion. Similarly, each calcium atom (group 2) can give up two electrons and transfer one to each of two chlorine atoms to form CaCl2, which is composed of Ca2+ and Cl− ions in the ratio of one Ca2+ ion to two Cl− ions. A compound that contains ions and is held together by ionic bonds is called an ionic compound.