Now that you understand how elements combine to form compounds it's time to learn how to write the formulas for ionic and covalent compounds.


When aluminum and oxygen combine, aluminum loses 3 valence e- but oxygen can only accept 2 e-. You can see that this presents a problem - aluminum is left with one valence electron. So you need another oxygen atom to take aluminum's leftover valence electron. But then oxygen needs another electron to become stable so you need another aluminum atom... It's all pretty confusing, right? Wrong.

All you have to do is use the valence of each element. Valence (also known as oxidation number) is the charge an atom takes when it loses or gains electrons and becomes a stable ion. You can easily figure the valence of an element by looking at the periodic table. Alkali Metal lose 1 e- have a valence of +1, Alkaline Earth Metals lose 2 e- and you have a valence of +2... and so on. For the Nonmetals: Halogens gain 1 e- have a -1 valence, Oxygen Family elements gain 2 e- and take on a -2 valence...

So when you look at the periodic table you can see a trend in the A-Group elements (we will get to the transition metals later). Here it is - you need to learn it.

When writing an ionic formula between a metal and a nonmetal follow these 5 steps:

  1. Write the symbols for the metal and the nonmetal.
  2. Write the valences as superscripts above each symbol.
  3. Drop the + and - sign.
  4. Crisscross the valences so they become the subscript for the other element.
  5. Reduce subscripts whenever possible. Only when both are divisible by a number greater than one.

Let's use these rules to figure out the chemical formula for our compound between aluminum and oxygen.

Here are two examples where you must reduce:

That's all there is to writing a formula for a binary (only two elements) ionic compound between an A-Group metal and a nonmetal.

Using a periodic table try these then check your answers.

  1. sodium and phosphorus
  2. magnesium and fluorine
  3. aluminum and sulfur
  4. calcium and nitrogen
  5. barium and iodine
  6. potassium and bromine
  7. aluminum and phosphorus
  8. strontium and oxygen
  9. magnesium and nitrogen
  10. cesium and phosphorus

Check Answers


The transition metals are located between 2-A and 3-A on periodic table. They are called transition metals because their valences change - there is no orderly arrangement of valences in this group. Also some of these metals can lose inner energy level electrons as well as valence electrons which means they can have multiple valences. Iron can lose 2 e- in some reactions and take on a +2 charge while in other reactions it can lose 3 e- and take on a +3 charge. So how can you tell the valence when the periodic table doesn't help? By looking at the roman numeral in their name.

Iron with a +2 valence is called Iron(II)) while iron with a +3 valence is called iron(III). Here are some other transition metals cations:

Mn+4 = manganese(IV)
Mn+2 = manganese(II)
Cu+1 = copper(I)
Pb+4 = lead(IV)
Pb+2 = lead(II)
Au+1 = gold(I)

Cu+2 = copper(II)
Ag+1= silver(I)

Au+2 = gold(II)

* all metals always lose electrons and take on a positive charge. The + sign is not shown in the roman numeral.

Using a periodic table try these then check your answers.

  1. iron(III) and phosphorus
  2. copper(II) and fluorine
  3. silver(I) and sulfur
  4. manganese(II) and nitrogen
  5. lead(IV) and iodine
  6. copper(II) and bromine
  7. gold(II) and phosphorus
  8. lead(IV) and oxygen
  9. silver(I) and nitrogen
  10. copper(II) chloride

Check Answers


Some compounds contain a polyatomic ion (many atom ion - a molecule with a charge). Here is a list of some common polyatomic ions.

+ 1 cations
- 1 anions
- 2 anions
- 3 anions
Ammonium NH4 +1
Hydroxide OH -1
Carbonate CO2 -2
Phosphate PO4 -3

Nitrite NO2 -1
Sulfite SO3 -2

Nitrate NO3-1
Sulfate SO4 -2

When you write formulas for compounds containing a polyatomic ion:

  1. Write the symbols for the metal and the polyatomic ion.*
  2. Write the valences as superscripts above each.
  3. Drop the + and - sign.
  4. Crisscross the valences so they become the subscript for the other element.
  5. If you have more than one of the polyatomic ion, you must encase it in parenthesis and place the subscript outside.
  6. You can only reduce a subscript outside the parenthesis of a polyatomic ion - you cannot change the formula the polyatomic ion.

*In the case of ammonium (the only polyatomic cation) you would write it first and then the anion.

Here are some examples of writing formulas with polyatomic ions:

Try these using a periodic table an a list of polyatomic ions.

  1. aluminum and sulfate
  2. ammonium and sulfur
  3. barium and hydroxide
  4. magnesium and phosphate
  5. lead(IV) and sulfite
  6. strontium and carbonate
  7. zinc(II) and phosphate
  8. ammonium and oxygen
  9. calcium and nitrate
  10. tungsten(II) and sulfate

Check answers


We saved the easiest formulas for last.

In ionic compounds you always crisscross valences to determine the formulas. In covalent compounds atoms share electrons so there isn't any valence to crisscross. IMPORTANT: You never crisscross valences to determine covalent (two nonmetals) formulas. So just how do you write the formulas? Prefixes - that's how.

Because covalent compounds share electrons they can share in different ways and can form many compounds between the same two elements. For example, you know two compounds that that exist between carbon and oxygen: CO carbon monoxide and CO2 carbon dioxide. The NAMES of covalent compounds contain prefixes that tell you how many atoms of each element is in the compound. Here are the prefixes used in covalent compounds:

*a and o is used if element begins with a consonant, dropped if it starts with a vowel

Here are six covalent compounds that form between nitrogen and oxygen: nitrogen monoxide = NO, nitrogen dioxide = NO2, dinitrogen oxide = N2O, dinitrogen trioxide = N2O5 , dinitrogen tetroxide = N2O4 and dinitrogen pentoxide = N2O5.

That's all there is to it. Just look at the name and you have the formula for a covalent compound.

Go ahead and try these:

  1. sulfur dioxide
  2. dihydrogen oxide
  3. phosphorus pentafluoride
  4. carbon tetrachloride
  5. aluminum trichloride

Check answers

That's it. You should now be able to write the formula for ionic and covalent binary compounds (containing only two elements) as well as formulas for ionic compounds containing a polyatomic ion. Now it's time to learn how to name chemical formulas.