Ignition timing is the measurement, in degrees of crankshaft rotation, of the point at which the spark plugs fire in each of the cylinders. It is measured in degrees before or after Top Dead Center (TDC) of the compression stroke.
Ideally, the air/fuel mixture in the cylinder will be ignited by the spark plug just as the piston passes TDC of the compression stroke. If this happens, the piston will be beginning the power stroke just as the compressed and ignited air/fuel mixture starts to expand. The expansion of the air/fuel mixture then forces the piston down on the power stroke and turns the crankshaft.
Because it takes a fraction of a second for the spark plug to ignite the mixture in the cylinder, the spark plug must fire a little before the piston reaches TDC. Otherwise, the mixture will not be completely ignited as the piston passes TDC and the full power of the explosion will not be used by the engine.
The timing measurement is given in degrees of crankshaft rotation before the piston reaches TDC (BTDC, or Before Top Dead Center). If the setting for the ignition timing is 10 BTDC, each spark plug must fire 10 degrees before each piston reaches TDC. This only holds true, however, when the engine is at idle speed.
As the engine speed increases, the pistons go faster. The spark plugs have to ignite the fuel even sooner if it is to be completely ignited when the piston reaches TDC.