Ionic bonds are formed between non-metals and metals through an electron transfer. The resulting ions are held together by the electrical attraction of opposite charges, as for example in sodium chloride (NaCl) or potassium chloride (KCl) (Figure 1). Ionic bonding leads to the formation of an ionic or crystal lattice. When a cation forms an ionic bond with an anion the number of negative charges is typically equal to the number of positive charges and thus every ionic compounds is overall electrically neutral.
Figure 1: Ionic bond between Potassium (K+) ion and Chlorine ion (Cl-)