In an ionic bond, an electron leaves one atom to join another, while a covalent bond is a sharing of electrons between two atoms. Polar covalent bonds occur when two atoms share an uneven number of electrons.
Chemical bonds form due to interactions between valence electrons in atoms. Valence electrons occupy the outermost shell or energy level of an atom. If the valence shell is filled with the maximum number of possible electrons, it is a closed shell. Atoms with closed shells tend to be inert and unlikely to react with other atoms and molecules. Atoms with open valence shells are likely to receive, donate or share electrons in order to form a closed shell.
Ionic bonds involve the complete transfer of electrons from one atom to another and require a donor and a receiver. Atoms with few electrons in the outermost shell are most likely to donate, while atoms with many valence electrons often receive more to form a closed shell. Ionic bonding leads to the formation of two charged atoms, or ions. One example is salt, or sodium chloride. Sodium atoms readily donate electrons, which results in a positive charge. Chlorine atoms accept these electrons, becoming negatively charged. The two oppositely charged atoms then attract one another to form a sodium chloride molecule.
Some atoms share electrons to gain a closed shell; this is called covalent bonding. Oxygen atoms, for example, require two additional electrons to form a closed shell, while hydrogen atoms require one. An oxygen atom readily shares two of its electrons with hydrogen atoms so that all three atoms have closed shells. The arrangement creates a water molecule. However, oxygen exerts a greater pull on the electrons than hydrogen does; thus, the shared electrons spend more time around the oxygen atom than around the hydrogen atoms. The oxygen atom then carries a partial negative charge, and the hydrogen atoms each carry a partial positive charge. The bond that results in this unequal charge is called a polar covalent bond.