Why mpg and L/100 km are inverse
Miles per gallon measures distance per unit of fuel, while liters per 100 km measures fuel per unit of distance. That is why a higher mpg is better but a lower L/100 km is better, and why the conversion is a division: L/100 km = 235.215 ÷ mpg (US).
US and UK gallons are different
A US gallon is 3.785 liters and an imperial (UK) gallon is 4.546 liters. The same car therefore shows about 20% more mpg in the UK than in the US: 30 mpg (US) is 36 mpg (UK). Always check which gallon a figure uses.
Formulas
L/100 km = 235.215 ÷ mpg (US) = 282.481 ÷ mpg (UK). km/L = 100 ÷ L/100 km. mpg (US) = 2.352 × km/L.