What are Heirlooms?
Heirloom is an item type that was introduced with Wrath of the Lich King. The items have a golden hue in their text color, and their attributes scale with the character's level. Nearly all heirloom items are named after popular items from the early days of Classic WoW, and share the look of these items.
Like the above quotation states, heirlooms were first introduced at the beginning of Wrath. They are arguably the strongest pre-80 items you can get. They scale to blue items at your level; so the stronger you get, the stronger the heirlooms get. I once read and agree with the statement "Heirlooms are Blizzard's way of saying thank you for playing the game from level 1 to level 85."
What type of Heirlooms do you get?
You get 2 types, PVE (Player-versus-environment) and PVP (Player-versus-player); each giving stats that gives you a performance boost for the respective type. Divided up between PVE and PVP, you get head/helm, shoulders, back/cloak, chestpieces, weapons, trinkets and coming soon rings. The PVP heirloom spread is more restricted than PVE as you only get shoulders, weapons and trinket PVP heirlooms were the rest of the pieces are exclusive to PVE.
Why should I get Heirlooms?
If you plan to level an alt/s, Heirlooms makes your life easier. You will be able to survive almost everything on your level and on a plus side, Armor Heirlooms give xp boosts, head, shoulders and chest Heirlooms each gives 10% extra xp and cloaks give 5% extra xp and they stack with each other, giving a grand total 35% extra xp (plus the guild perks).
How do I get Heirlooms?
There is one universal way, hard work. Reaching 85 (or atleast 80) is the first hurdle and after that you have to start farming the required resources. PVP heirlooms (weapons, shoulders and trinkets) are bought with Honor Points; to get Honor points, you have to do PVP (Random battlegrounds and such. Duels don't count). PVE heirlooms (weapons, shoulders, chestpieces and trinkets) are bought with Justice points; to get Justice points, you will have to do Heroic instances. To get cloaks and helm heirlooms, you have to join a level 20 guild and earn honoured reputation, after that, guild heirlooms cost gold. You can also use Champion's Seals which you can get from the Argent Tournament in Northrend, which you primarly get by doing daily quests. Champion's seals can be used instead of Justice points.
For more info on heirloom "currency" see:
My 85 is Horde but I want to level an Alliance character.
Have no fear, heirlooms don't know faction, you can send them to any your toons in the opposite faction, as long as they are on the same realm. You can NOT however send them to a different account because they are account bound.
How much do Heirlooms cost?
Most armor and one-handed weapons cost 2175 Honor/Justice points per item and the most expensive (which are ranged and two-handed weapons) cost 3500 points per item. The cheapest guild heirlooms are the cloaks which go for 1200 gold per cloak and helms cost 1500 gold per helm.
I want to roll a Warrior/Paladin or Shaman/Hunter, what armor should I buy?
Always the strongest armor your class can wear. Warriors and Paladins can only wear mail until level 40 then they can wear plate and it is the same for Shamans and Hunters who begin with leather and get mail later on. Don't buy mail for a Warrior or a Paladin, get them the plate heirlooms; if he cannot wear plate yet, the armor will scale down to mail and will become plate when you learn it from the trainer. Buy mail for Shamans and Hunters, pre-40, it will be considered leather armor until they learn to wear mail. This doesn't work for druids, rogues and the cloth classes; if you have a rogue, buy the leather heirlooms; if you have a mage, buy the cloth heirlooms.