The Basic Formula for MPG

Miles per gallon is the distance your car travels on one gallon of fuel. To calculate it, you divide the number of miles driven by the number of gallons used. That's the entire calculation: miles driven ÷ gallons used = MPG.

The challenge is getting accurate numbers for both parts. Most people measure miles from their odometer, which is straightforward. The gallons part requires you to track how much fuel you actually put in the tank, which means paying attention at the pump rather than just swiping your card and leaving.

You can calculate MPG for a single tank, over several tanks, or across months of driving. A longer period gives you a more realistic picture because it smooths out the variation that comes from different driving conditions on different days.

Key Takeaways

  • MPG is calculated by dividing miles driven by gallons of fuel used, and you need accurate odometer and pump readings to get a real number.
  • Fill your tank completely at the start and end of each measurement period so you know exactly how much fuel went into your car.
  • Measuring MPG over multiple tanks or a full month gives you a more accurate picture than a single tank, because driving conditions vary.
  • Your actual MPG will be lower than the EPA estimate on your window sticker because those tests use controlled conditions, not real-world driving.
  • Tracking MPG over time helps you spot when your car's fuel economy drops, which can signal maintenance problems like a clogged air filter or worn spark plugs.

How to Measure Miles Driven Accurately

Write down your odometer reading at the moment you fill your tank completely. Do the same thing the next time you fill up. The difference between those two numbers is the miles you drove on that tank. If your odometer read 45,230 miles when you filled up, and 45,580 miles at the next fill-up, you drove 350 miles.

The odometer on your dashboard is reliable for this purpose. Modern cars record it electronically, and it is the same number your mechanic uses to schedule maintenance. You do not need to worry about it being off by a few miles—the small variations average out over multiple tanks.

If you are measuring over a longer period, you can use the trip odometer instead. Reset it to zero when you fill up, then note the trip mileage when you fill up again. This avoids having to write down long numbers and is easier to track if you are measuring across several weeks.

How to Measure Fuel Used at the Pump

The most accurate way is to fill your tank to the same level each time. Pull up to the pump, insert the nozzle, and stop when the pump clicks off—do not top it off or squeeze extra fuel in. Write down the number of gallons the pump shows. The next time you fill up the same way, the difference is how much fuel you used.

If your first fill-up showed 12.5 gallons and your second showed 14.2 gallons, you used 1.7 gallons to drive those 350 miles. That gives you 350 ÷ 1.7 = 205.9 MPG, which is obviously wrong—this is just an example of the math, not a real number.

Consistency matters more than perfection. If you always fill to the click and always record the pump number, your measurements will be comparable to each other. Small variations in how full you fill the tank will average out over time and will not change the overall picture of whether your fuel economy is improving or getting worse.

Why Your Real MPG Is Lower Than the EPA Estimate

The EPA sticker on a new car shows an estimated MPG number based on controlled laboratory tests. Those tests use a dynamometer (a machine that simulates driving) in a climate-controlled room, with a specific driving pattern, no traffic, and no idling. Real driving includes stop-and-go traffic, cold starts, highway speeds, and varying weather—all of which use more fuel.

Your actual MPG will typically be 15 to 30 percent lower than the EPA highway estimate and 10 to 20 percent lower than the EPA city estimate, depending on how you drive. If the sticker says 28 MPG highway, you might see 20 to 24 MPG in real life. This is not a defect in the car; it is the difference between a test and the road.

Newer cars (2008 and later) use EPA estimates that are closer to real-world numbers than older tests were, but the gap still exists. Knowing this helps you understand why your calculation does not match the window sticker and why comparing your number to the EPA estimate is not a useful way to tell if something is wrong with your car.

Tracking MPG Over Time to Spot Problems

Calculate your MPG every time you fill up and write it down—in a notebook, a spreadsheet, or a note on your phone. After five or six fill-ups, you will see a pattern. Most drivers see MPG that varies by a mile or two from tank to tank depending on driving conditions, but the average stays roughly the same.

If your average MPG drops by more than 10 percent over several weeks, something has changed. Common causes include a clogged engine air filter, worn spark plugs, low tire pressure, a stuck brake caliper, or a failing oxygen sensor. These are all maintenance issues that a mechanic can diagnose. Catching the drop early means fixing the problem before it damages other parts or leaves you stranded.

Conversely, if your MPG improves over time, it usually means your engine has broken in (if it is a new car) or you have changed your driving habits. Steady acceleration, maintaining steady highway speeds, and reducing idling all improve fuel economy. Tracking the number gives you real feedback on whether those changes actually work.

Using Your Car's Onboard Computer

Many modern cars display a fuel economy reading on the dashboard or infotainment screen. This is a convenience, but it is not the same as calculating MPG yourself. The onboard computer estimates fuel economy based on engine sensors and does not measure the actual fuel that went into your tank.

Onboard readings are often optimistic—they may show higher MPG than you actually get when you do the math at the pump. Use the onboard display as a rough guide to how you are driving (it updates in real time and can show you when aggressive acceleration or idling hurts economy), but verify the real number by calculating it yourself at least once a month. This gives you a true baseline to compare against.

If the onboard display and your pump calculation differ by more than 10 percent consistently, the display may need recalibration, but this is rare. More often, the difference is because the display rounds numbers or uses a different time window than you do.

Common Mistakes When Calculating MPG

The most common mistake is not filling the tank completely. If you fill to the click one time and to a different level the next time, your gallon count will be off, and your MPG will be wrong. Always use the same fill method—pump until it clicks, then stop.

Another mistake is including fuel from a partial tank at the start. If you begin measuring when your tank is half full and fill it up, you are not measuring a full tank's worth of driving. Start your measurement at a full fill-up, and end it at the next full fill-up. Anything in between does not count.

Some people calculate MPG from a single tank and assume that is their true number. One tank can be skewed by a long highway drive, a week of city traffic, or even a change in weather. Measure across at least five or six fill-ups—ideally a full month—to get a number that represents your actual driving pattern.

Frequently Asked Questions

Can I calculate MPG if I do not always fill my tank all the way?

You can, but it requires more work and is less accurate. You would need to know your tank size and estimate what fraction of the tank you added at each pump visit. It is much easier to commit to always filling to the click. This takes no extra time and gives you exact numbers.

What if I use a fuel card or app that tracks my fill-ups?

Those tools can record the gallons for you, which saves time on data entry. However, you still need to record the odometer or trip mileage yourself. The app or card does not know how far you drove—only how much fuel you bought. You have to do the division yourself or enter the mileage so the app can calculate it.

Does MPG change with the season?

Yes. Cold weather reduces MPG because engines run less efficiently when they are cold, and winter fuel blends are formulated differently than summer blends. You might see 2 to 5 percent lower MPG in winter than in summer. This is normal and does not mean something is wrong with your car.

Should I calculate MPG differently for highway versus city driving?

You can if you want to see the difference, but it requires tracking mileage and fuel separately for each type of driving. For most owners, one overall MPG number is useful enough. If you want to compare highway and city, reset your trip odometer when you start highway driving, then calculate MPG for just that portion at the next fill-up.

What MPG should I expect from my car?

Check your owner's manual or the EPA sticker if you have the original paperwork. Expect your real-world number to be 15 to 30 percent lower than the EPA highway estimate. If your car is significantly older or has high mileage, MPG may be lower than the original estimate because engine wear and carbon buildup reduce efficiency over time.