The ratio between the cylinder volume at BDC (bottom dead center) and at TDC (top dead center). Higher ratios make more power but require higher octane fuel.
Compression ratio is the ratio between the cylinder volume when the piston is at BDC (bottom dead center, the lowest point) and when at TDC (top dead center, the highest point). Higher compression ratios extract more energy from the air-fuel mixture, producing more power and better fuel economy. The trade-off is requirement for higher-octane fuel; high compression engines are more prone to knock if low-octane fuel is used.
Typical compression ratios in modern engines: 9.5:1 to 10.5:1 for most economy and mid-range engines. 10.5:1 to 12:1 for performance engines. 12:1 to 13:1 for high-performance naturally aspirated engines (Honda Civic Type R, Mazda Skyactiv-X, certain Lexus engines). Forced induction engines typically have lower compression ratios (8:1 to 10:1) because boost provides additional pressure; high static compression plus boost can cause knock.
Compression ratio is determined at engine assembly. Some performance modifications increase compression by using thinner head gaskets, decking the head or block, or using high-compression pistons. The result is more naturally aspirated power but increased octane requirement. Some forced induction modifications decrease compression (thicker gaskets, lower compression pistons) to allow more boost without knock. Modern engines with knock sensors can adjust ignition timing for varying fuel octane, providing some flexibility.