|Guitar pitch pipes, Wikimedia|
It's possible to tune by ear using tuning forks or pitch pipes. Tuning by ear is a useful skill and it's what orchestral players often do (because some instruments like pianos cannot be retuned easily, so you have to tune to match them). But it takes lots of practice to do efficiently.
Heads upThe cheapest practical alternative are electronic headstock tuners. These are all broadly similar, but performance can vary. I have a Snark SN-8 'super tight' which is better than previous ones I've tried (guitarman, guitartech), achieving a faster and more stable lock onto the note. When using a headstock tuner try to put it where vibration on the headstock is strongest.
|Snark SN-8 on left and Guitarman on right|
On your bikeThe next type of tuner is a pedal tuner: these use the same electronics to analyse the signal, but instead of using a piezo-pickup to detect the note on the headstock they plug into your guitar's signal chain (obviously you need an electric or electroacoustic to use these).
There are advantages and disadvantages to pedal tuners. They are a bit more expensive and not as easy to carry around as headstock tuners, and if you're using a plain acoustic guitar then you have no way to plug it in.
But pedal tuners really shine on stage. Since they read the guitar signal they will still work even in the presence of background noise (headstock tuners might be confused by loud background). They will also often allow you to mute while tuning and can be there all the time while not threatening to fly off at the wrong moment.
Recent pedal tuners like polytunes also offer the ability to tune multiple strings at once, so you just strum and it tries to lock and show all six notes.
These days a good tuner program for your computer can get as good accuracy provided you have a way to plug your instrument in. I like Lingot http://freecode.com/projects/lingot, which also has a Windows version, http://lingot.gitara.org.pl/index.php.en. Under Linux Lingot can read from Jack or ALSA (and therefore also Pulseaudio), so whatever setup you're using it will probably work. It also supports Scala files so there is a large set of altered (non-TET12) tunings available and being able to display the spectrum lets you see how well the notes are being detected.