This is an old revision of the document!
Gears are one of those mechanical devices that everybody knows how they work, but until you need to incorporate on into your next project, you usually don't know the details behind all the theory of gear design. Gears are a fundamental simple machine that provide mechanical advantage, trading rotational speed for rotational force (or “torque”).
For a detailed primer on gears, see Wikipedia's Gear Page
For standard “spur” gears with parallel axes, the most common shape for the gear teeth is called an involute. This shape ensures that the mating surface of two gears is always perpendicular to direction of motion. This is desirable because it means that the force is transmitted in parallel with the motion. In other words, the gears don't exert forces on each other's axes.
This page is a collection of link to resources on the Internet for generating gear designs. Some are free, some may not be.
FreeCAD http://www.freecadweb.org/
FreeCAD as of version 0.15, has a basic Parametric Gear creation tool.
(Free, Windows, Linux, Mac)
Gear Template Generator https://www.woodgears.ca/gear_cutting/template.html
You can generate basic gear profile templates in the Flash based Web version and send to a printer, or buy the Windows offline version to generate DXF files, among others. It also supports “rack and pinion” gear profile creation.
(Web Application - Free, Windows Application - Commercial)
If your gear is purely cosmetic in nature, or what you need is a sprocket for driving a chain, check out Sprocketeer 2 (Free, Windows Application, Web Application)