Earbuds are best for people who are short on space, but still want a way to listen to their music. The higher-quality earbuds, like from Sennheiser or Ultimate Ears, usually come with little cases to put your earbuds in when you're not using them, so they won't get ruined or dirty at the bottom of your bag. If you keep a very smallpurse and want to keep your iPod Nano and earbuds together in it, or you're a guy with limited pocket space, earbuds are probably a better choice. They're also great if you are on a limited budget, because there's a lot more to choose from and they tend to cost less.
Headphones are great if you enjoy putting them around your neck while you're walking from one place to another, or if you just carry your headphones that way. You also tend to get beefier cords and fun options like wireless/bluetooth headphones. The drawback is that good headphones within your budget might be hard to find. They take up more space than earbuds, and the DJ-style headphones take up a ridiculous amount of space if you don't carry around a larger bag. They also are easy to get dirty because most don't come with cases for them.
Remember that you get what you pay for. Generally, more expensive headphones are made with higher quality materials and better engineering, improving the sound quality. $30 headphones will sound good, but not as good as $60 ones. Up in the $80-90 range, you may hear stuff in your music that you've never heard before. $9.99 bargain bin earbuds or headphones may last, at longest, a year, and will not sound great to begin with. So spending at least $20 on them insures you at least get basic music quality. One guideline is to spend $50 on portable headphones and $250 on a pair for a home stereo. Another thing you get with quality is durability. There are probably people out there with headphones from the 70's and 80's that still work because they're made well, and made to last. When you get a brand name you aren't just paying for the name sometimes; you're paying for the trusted quality.
Evaluate the headphones' sound isolation. This refers to how well they keep music in and block outside noise. Nothing's more annoying than having to turn up your volume to drown out the sound of the bus. There's also the fact that if you're rather deaf, enjoy turning your music up loud, and/or use it to drown out background noise and the headphones are very open, you'll end up giving everyone around you something to gossip about. Sound isolation will also keep you from having to waste precious battery life or turn up the volume to hear properly.
Investigate the frequency range. A wider frequency range means you can hear more from the music; large ranges such 10 Hz to 25,000 Hz will often be recommended - anything within that range will be fine.
Earbuds and in-ear headphones tend to be better at sound isolation, due to the seal they provide in your ear; and the same with (huge) DJ-style headphones that create a little sealed environment around the ear.
Don't look for noise-canceling features unless you're willing to shell out the big bucks. Anything less than around $200-250 isn't worth the price. Even if you're the frequent traveler type, noise-canceling, 90% of the time, just isn't worth the money. Some of your music might get canceled out as well, forcing you to turn up the volume. If you really do need noise reduction, however, look for brands like Etymotic, or Bose which have spongy earplugs that fill the ear canal.
Test them out. The best way, really, to know if headphones can go loud enough for you is to test them out. Try on a friend's pair (if they're cool like that) or go to a good electronics store that will let you try on the headphones. Having around $200 in cash handy and going to a store with a 30-day return policy will make the electronics store your unwilling friend while you learn what types of headphones you really want. Out of courtesy, however, always clean the wax out of your ears before trying on any headphones or earbuds!
Look for the impedance of the headphones. To get the best out of your headphones, you should match the impedance of the headphones to the audio equipment you are using. This is measured in ohms. In reality if you don't this usually means that you will need to turn up the volume slightly compared to a matched pair of headphones.
Finally, use your ears! You are the person who is going to be using these headphones day in day out. If a $50 pair of headphones sounds the same as a $1000 pair of headphones, go for the cheaper pair. The sound quality is not going to change just because they are more expensive! The only thing to remember is the overall build quality of the headphones - are they going to last as long? Does it matter if they are that much cheaper?