Sure, happy endings are easier to appeal the masses, and it can be great if they are well done, but that also applies to bad/sad endings. Imo, what's the most important is for the ending to be consistent with the rest of the game, nothing more, nothing less. And needless to say, I believe it's much harder to pull off a bad/sad ending that would still please the player.
Some amazingly consistent non-happy endings:
- Fallout
- Deus Ex
- Half-Life
- Kotor 2
- Planescape: Torment (I don't remember it well, but I know it was one of the best endings ever)