Atoms can join together by forming a chemical bond, which is a very strong attraction between two atoms. Chemical bonds are formed when electrons in different atoms interact with each other to make an arrangement that is more stable than when the atoms are apart.
What causes atoms to make a chemical bond with other atoms, rather than remaining as individual atoms? A clue comes by considering the noble gas elements, the rightmost column of the periodic table. These elements—helium, neon, argon, krypton, xenon, and radon—do not form compounds very easily, which suggests that they are especially stable as lone atoms. What else do the noble gas elements have in common? Except for helium, they all have eight valence electrons. Chemists have concluded that atoms are especially stable if they have eight electrons in their outermost shell. This useful rule of thumb is called the octet rule, and it is a key to understanding why compounds form.
There are two ways for an atom that does not have an octet of valence electrons to obtain an octet in its outer shell. One way is the transfer of electrons between two atoms until all atoms have octets. Because some atoms will lose electrons and some atoms will gain electrons, there is no overall change in the number of electrons, but individual atoms acquire a nonzero electric charge. Those that lose electrons become positively charged, and those that gain electrons become negatively charged. Charged atoms are called ions. Because opposite charges attract (while like charges repel), these oppositely charged ions attract each other, forming ionic bonds. The resulting compounds are called ionic compounds and are the primary subject of this chapter.
The second way for an atom to obtain an octet of electrons is by sharing electrons with another atom. These shared electrons simultaneously occupy the outermost shell of more than one atom. The bond made by electron sharing is called a covalent bond. Covalent bonding and covalent compounds will be discussed in detail below.