Octane rating is a method for describing antiknock properties of gasoline . Knocking is a pinging sound produced by internal combustion engines when fuel ignites prematurely during the engine's compression cycle. Because knocking can damage an engine and rob it of power, gasoline formulations have been developed to minimize the problem. Gasolines containing relatively large amounts of straight-chain hydrocarbons (such as n-heptane) have an increased tendency to knock, whereas those containing branched-chain forms (such as isooctane) burn more smoothly. In addition to isooctane, other compounds also reduce engine knocking. By using an index called octane number, it is possible to compare the antiknock properties of gasoline mixtures. A higher octane number indicates that a mixture has the equivalent antiknock properties of a gasoline containing a higher percentage of isooctane.
Although gasoline used as automotive fuel is now "deleaded," gasoline used as aviation fuel still contains tetraethyl lead as an octane enhancer and antiknock agent.