A dynamo is a small electrical generator which uses the motion of the wheels to generate electricity.

Most bicycles used for everyday transport in the Netherlands and in Denmark use dynamos to power their lights. The dynamos (and the lights) are a permanent feature of the bicycle, meaning lights are always available when they are needed, and the inconvenience of having to take lights on and off the bicycle with every trip is removed. Modern dynamo lighting is also very efficient, and does not present any appreciable drag while cycling.

Dynamos are of two types; hub dynamos, built into the hub of the front wheel, and bottle dynamos, which run on the sidewall of the tyre. 

Hub dynamos are slightly more efficient, when running, but bottle dynamos do not increase rolling resistance when they are not in use. 

Shimano hub dynamo