The atomic mass, as the name cleverly suggests, gives the mass of an atom, allegedly the tiniest piece of elementary matter. It can be given in any unit of mass, like the kilogram or the pound, or if you feel gutsy, in electronvolts. Very often the 'atomic mass' is also called 'atomic weight' for historical reasons1. As one can imagine, the mass of an atom is very small, around 10-26 kg. So, instead of using this unwieldy 10-26 all the time, it is a lot easier to use a different unit for the mass of atoms - the 'atomic mass unit'. It is abbreviated 'amu' or more commonly just 'u'. The mass in 'kg' and in 'u' are related by:
1 u = 1.6605×10-27 kg
1 kg = 6.022×1026 u
The atomic mass of every type of atom, or element, which should more accurately be called 'average atomic mass', is tabulated in the periodic table of the elements. It gives the average atomic mass of an element under consideration of the natural occurrence of isotopes.
But why is 1 u = 1.6605×10-27 kg? There is a long history behind that, taking us all the way back to 460 BC, but the practical reason will be given here: The 'atomic mass unit' works like a conversion factor between the number of molecules (given in the unit 'mole') and mass in grams (which is easily determined using a simple balance). One mole is equivalent to 6.022×1023 units of things2 - it's just a different way of saying 'a lot', but a very specific one: In the case of the atomic unit, it has been agreed that its value is based on the atomic mass of the 12-carbon isotope - one atomic unit corresponds to one twelfth of the mass of a 12-carbon atom. In this way the atomic unit represents roughly an average value between the mass of a proton and the mass of a neutron in a nucleus3. The principle is best illustrated by looking at two examples:
Ethanol (C2H5OH) is made of two carbon atoms, one oxygen atom and six hydrogen atoms. The periodic table lists carbon with a mass of 12 u, oxygen 16 u and hydrogen 1 u. Ethanol therefore has a mass of 46 u. Using the conversion factor, one molecule of ethanol thus weighs 7.64×10-26 kg. The other way round, using the 'mole' equivalent, one mole of ethanol has a mass of 46 grams; dividing that mass by 6.022×1023 - the number of molecules in a mole - one will obtain a mass of 7.64×10-26 kg per molecule: Not surprisingly, the same mass as calculated before.
Table salt, otherwise known as sodium chloride (NaCl), has a basic unit consisting of one sodium atom and a chlorine atom. Chlorine has a mass of 35.5 u (note that the mass is not an integer because of the distribution of isotopes, roughly 75% of the chlorine atoms in NaCl are 35-Cl and 25% are 37-Cl). Sodium has a mass of 23 u (nearly all sodium is 23-Na). One mole of table salt therefore has a mass of 58.5 grams. One NaCl unit therefore has a mass of 9.71×10-26 kg.
This equivalence between the mass and the number of molecules turns out to be extremely handy for any chemist trying to cook up a chemical compound: instead of counting individual molecules, it's possible to simply weigh and determine the mass of a substance and figure out how many molecules exist in there.