To calculate MPG, divide the miles you drove by the gallons of gas you used: 300 miles on 12 gallons is 300 ÷ 12 = 25 miles per gallon. MPG, or gas mileage, tells you how far your car goes on one gallon, so the higher it is, the less you spend. This guide shows how to measure your MPG at the pump, average it over several tanks, turn it into gallons per 100 miles and use it to work out what a trip will cost in gas.
How to calculate MPG at the pump
The most reliable way to calculate gas mileage is the fill-up method, because it uses the gallons the pump measured rather than an estimate:
- Fill the tank until the pump clicks off, and reset your trip odometer (or write down the odometer reading).
- Drive normally until you need gas again.
- Fill the tank again, stopping at the first click as before, and note the gallons on the pump’s display. That is the gas you used since the last fill-up.
- Divide the miles on the trip odometer by those gallons.
The formula is:
MPG = miles driven ÷ gallons used
If you drove 342 miles and the second fill-up took 11.4 gallons, your car got 342 ÷ 11.4 = 30 MPG on that tank.
Average MPG over several tanks
One tank can mislead: a week of highway driving and a week of school runs give very different numbers. Track a few fill-ups and divide the total miles by the total gallons:
| Fill-up | Miles | Gallons | MPG |
|---|---|---|---|
| 1 | 342 | 11.4 | 30.0 |
| 2 | 198 | 9.0 | 22.0 |
| 3 | 310 | 11.0 | 28.2 |
| Total | 850 | 31.4 | 27.1 |
Your average is 850 ÷ 31.4 = 27.1 MPG.
Note: do not average the three MPG figures (30.0, 22.0 and 28.2 average 26.7). That gives a short tank the same weight as a long one; dividing total miles by total gallons weighs each tank by how far you drove on it.
MPG and gallons per 100 miles
MPG says how far you go on a gallon; gallons per 100 miles says how much gas a set distance takes. To switch, divide 100 by your MPG:
gallons per 100 miles = 100 ÷ MPG
| MPG | Gallons per 100 miles | Gallons for 1,000 miles |
|---|---|---|
| 15 | 6.67 | 66.7 |
| 20 | 5.00 | 50.0 |
| 25 | 4.00 | 40.0 |
| 30 | 3.33 | 33.3 |
| 35 | 2.86 | 28.6 |
| 40 | 2.50 | 25.0 |
| 50 | 2.00 | 20.0 |
The table shows why the fuel economy label of a new car carries both. The EPA and the Department of Energy call it the “MPG illusion”: going from 10 to 15 MPG saves about 33 gallons over 1,000 miles, while the same 5 MPG jump from 30 to 35 MPG saves only about 5. Gallons per 100 miles tracks what you actually spend, so it is the better way to compare two cars.
The label’s combined MPG is not a plain average either: it is a weighted average of the city and highway figures, with the city value weighted at 55% and the highway value at 45%. Those are lab estimates, so the MPG you measure at the pump is the one to use for your own trips.
How to calculate the gas cost of a trip
Once you know your MPG, a trip’s gas cost takes two steps: divide the distance by your MPG to get the gallons, then multiply by the price per gallon.
gas cost = miles ÷ MPG × price per gallon
For a 450-mile drive in a car that gets 30 MPG, with gas at $3.20 a gallon:
| Step | Calculation | Result |
|---|---|---|
| Gallons | 450 ÷ 30 | 15 gallons |
| Cost | 15 × $3.20 | $48.00 |
| Per mile | $3.20 ÷ 30 | $0.11 |
The fuel cost calculator does this for you. Its units start in kilometers and liters, so set the distance to miles and the consumption to gallons first. It asks for the consumption per 100 miles rather than MPG, so enter 100 ÷ your MPG: 3.33 for a 30 MPG car. It also adds 5% for each person aboard, the driver included, so the same trip with only the driver comes to about $50.35 rather than the $48.00 of gas the formula gives. Luggage, a roof rack, air conditioning, open windows and expected traffic each add an allowance on top, and it splits the cost per passenger and per month for a trip you repeat.
What lowers your gas mileage
The fuel economy site of the Department of Energy and the EPA lists the habits that cost the most (fueleconomy.gov):
- Aggressive driving, meaning speeding, rapid acceleration and hard braking, “can lower your gas mileage by roughly 15% to 30% at highway speeds and 10% to 40% in stop-and-go traffic”.
- Extra weight: “an extra 100 pounds in your vehicle could reduce your MPG by about 1%”, more in a small car than a large one.
- Idling “can use a quarter to a half gallon of fuel per hour, depending on engine size and air conditioner (AC) use”.
Upkeep counts too: keeping your tires inflated to the proper pressure improves gas mileage by 0.6% on average, and up to 3% in some cases. Tracking your MPG at every fill-up is the easiest way to notice when it starts to slip.
How to calculate MPG in 4 steps
- Fill the tank and reset the trip odometer.
- Drive until you need gas, then fill up to the first click again and note the gallons.
- Divide the miles driven by the gallons: that is your MPG for the tank.
- To price a trip, divide its miles by your MPG and multiply by the price per gallon, or set the fuel cost calculator to miles and gallons and enter 100 ÷ MPG.