Funny...my 2 year old cat has done this to us since we brought her home at 9 weeks! So I guess it's not just dogs! Growing up our dogs did that, but never heard of a cat doing it! I have weird babies!!!
I was once told that dogs sniff behind people's ears to get a sense of their character and if they are good people. Not sure how true it is, but maybe it is an affection thing, with your dog showing you love and affection. Other than that they are trying to 'clean your ears.
Hi! My dog also loves to lick mine and my housemates ears! The main reason for this is a sign of affection! Your pooch is showing you he loves you and respects you!
A gross alternative is they like the taste of wax!