Ionic bonds are formed from metals and nonmetals or a metal and a polyatomic ions which are typically made of nonmetals.
Covalent bonds are formed from two or more nonmetals
If you look at the periodic table you can locate this stairstep. Elements to the left of the stair step are metals except for hydrogen which is a nonmetal and to the right are nonmetals.
Let's look at some examples of ionic bonds.
Sodium chloride
NaCl
If you look at the periodic table you will see sodium is on the left so it is a metal, and chlorine is on the right, so it's a nonmetal. A metal and a nonmetal results in an Ionic bond.
It’s made of potassium and bromide. Potassium is on the left so it's a metal, and bromide is on the right so it's a nonmetal.
What about this compound ? It has more than two elements like the previous example.
Lithium Nitrate
LiNO3
This compound is made up of lithium which is a metal and two nonmetals bonded together called nitrate, which is a polyatomic ion that has elements bonded together but act as one.
This is a covalent bond because it’s a metal and nonmetals bonding together.
What about sulfur dioxide?
It’s made of sulfur and oxygen which are both nonmetals so it is a covalent bond
How about water which has a formula of H2O?
It’s made of hydrogen and oxygen which are both nonmetals so it’s a covalent bond Remember although hydrogen is on the left it’s an exception and is a nonmetal.
How are the atoms held together in these different compounds?
Let’s look at covalent bonds first.
Compounds with covalent bonds are held together because they are sharing electrons.
Let’s look at water which illustrated above.
They are connected because they are sharing electrons and this holds the compound together.
Now let’s look at sodium chloride which is held together by an ionic bond.
The sodium becomes a positively charged ion called a cation and the chlorine becomes a negatively charged ion called an anion.
Now you have a negative and positive charge attracted to one another and this bonds the elements together.
So how can you remember the difference?
In order to remember covalent, I think of co-presidents which share the power or cohabitate where you share a space.
In order to remember ionic, I think "I want your electron" which results in gaining and losing an electron which results in creating an ion.