I have a couple of recommendations depending on what you plan on playing.
For pretty much any Nintendo games, the Wii Classic Controller is best and you can figure out how to use it by following the link in an earlier post. The setup of a Classic Controller is, of course, very similar to a SNES controller, and for that reason it is quite adaptable to either SNES or NES games. The Classic Controller is in my view one of the greatest controllers ever made and I couldn't recommend it more highly.
For Genesis and Saturn games, I highly, highly recommend a USB Saturn controller. Those things work extremely well for obvious reasons (the Saturn setup is identical to the Genesis one), and it controls flawlessly.
Barring that (still on Genesis games), use what I use: a MadCatz Street Fighter IV fightpad for the Xbox 360. It has gigantic buttons, one of the best and smoothest D-pads I've ever used, and is set up just like a Saturn controller with extra features like Turbo. Unfortunately, you'll have to deal with silly Street Fighter 4 characters on the faceplates. The advantage this one has is that it can be used on the Xbox 360, if you have one. Perfect for Sonic's Genesis Collection on that system.
Otherwise, pick up the Logitech Dual Action Gamepad for the PC. Unless you already own a Wii and the classic controller, this is your cheapest and most logical option. It's set up exactly like a Playstation controller, but unfortunately I don't think it's quite as smooth. My face buttons began to "stick" after a couple years, and the D-pad is less than ideal (again, it "sticks"), but don't let that fool you: this is a very good controller and I still use it if I have anything on the PC for which I want 3D control (alternately, I use my 360 controller...but the D-pad is much worse on that).
On a side note, for the SNES I found a perfect keyboard setup was WASD for the D-pad and PL:" for the face buttons, with L-Shift and R-Shift respectively serving as the left and right shoulder buttons and f replacing Select. Thought I'd throw that out there in case none of the controller options worked.
@Kazumi: My opinion on the 360 gamepad is that it's designed for 3D control and simply isn't suited for 2D games. Even third-party controllers tend to have this problem. The Playstation controller is much better, but from what I've heard it's not as easy of an option, so I dunno.