The distinctions between "geek" and "nerd" are many and various - or maybe there aren't any distinctions at all. The meaning of both always depends on who is using the term.
Geek is a cooler term for a fan. A devoted fan. An over-the-top, obsessive fan of some hobby or media. They are a part of some fandom or speciality, their jokes and allusions no one can get except other geeks, they spend money on their hobby instead of some Serious Business. They waste time debating their favourite media on message boards and writing articles about geeks in Wikipedia and TV Tropes. And if there were no conventions and no Internet, many of them would have never socialized.
For the record, geek is an old Carny term for a species of sideshow performer: a specialist in the art of eating disgusting things (emphasis here on "specialist"). Biting off the heads of live chickens was the classic play. Somewhere along the line, certain communities–notably info-tech communities–picked up the term as a synonym for "specialist". "He's an Emacs geek," for example, would mean he knows a lot about Emacs. Another concept of a geek is someone more interested in books or computers than social activities (much like a nerd), a person who doesn't "get" social activities at all. It was turned on its ear when geeks started becoming everyone else's boss after college. (See: Microsoft, Apple, Google, etc.)
Although recently the very word "geek" became increasingly associated with the fans of video games, TV shows and comic books, this doesn't exclude other fandoms and subspecialties. There are tech geeks. There are sports geeks. There are Fashion Geeks, people who know a lot about fashion and are pretty obsessed with it. A Fashion Nerd, in contrast, would be completely unaware that stripes and plaids are unmix-y, and wouldn't care, even if they're told why the two don't mix.
A Geek Hierarchy◊ was allegedly discovered for the first time in 2002 on the Brunching Shuttlecocks humor site.