Different malts can help head retention greatly. Basically, head retention is helped by adding more dextrins and proteins. These can be found in crystal malts like Carapils, Carafoam, and Caramel malts. Also, wheat and flaked barley can help.
You want to be careful you don't add too much though. Too many proteins can actually hurt your beer by reacting with tannins. This creates chill haze and cloudy beers. This can be helped by adding things like Irish Moss to the boil, but it won't fully prevent it.
Hops are also great for adding head retention. That's why most IPA's tend to have great head.
Not using household soaps and detergents helps. Your homebrew may have fine retention but you may not see it do to the glasses you use. Dish washing detergents can sometimes leave behind residue in your glasses and kill the head on your beer.
Another possibilty is maybe you aren't letting your bottles condition long enough and your carbonation just hasn't taken hold fully.
He who drinks beer sleeps well. He who sleeps well cannot sin. He who does not sin goes to heaven.
Another HERMS rig...