Fuel Cost Calculator
Enter your trip distance, your car's mpg, and the gas price — the cost updates as you type, and the link in your address bar always reflects your numbers.
How this calculator works
The math is simple, but getting the inputs right matters: fuel cost scales directly with how far you drive and how efficiently your car burns gas. If you're going round trip, we double the one-way distance first. Then we divide that effective distance by your car's mpg to get the gallons you'll need, and multiply the gallons by the price per gallon to get the total cost — gallons = distance ÷ mpg, cost = gallons × price. If you don't know your car's real mpg, our MPG calculator works it out from an actual fill-up in a few seconds.
Worked example
A 300-mile one-way trip in a car that gets 28 mpg, with gas at $3.50 a gallon: 300 ÷ 28 = 10.71 gallons, and 10.71 × $3.50 = $37.50. Check the round-trip box and the effective distance doubles to 600 miles, which needs 21.43 gallons and costs $75.00 — exactly double, as expected.
Frequently asked questions
Does this account for highway vs. city driving?
No — the calculator uses the single mpg figure you enter, and real-world fuel economy varies with driving conditions: highway cruising, city stop-and-go, hills, cargo weight, and weather all shift it. For the most accurate estimate, use your car's combined EPA rating (found on the window sticker or fueleconomy.gov) or, better, your own measured average from a recent fill-up.
Should I add a buffer for traffic or detours?
It's a good habit. Idling in traffic and taking a longer route than planned both burn extra fuel that a straight-line distance won't capture. A simple practical tip: pad your distance estimate by 5–10% before running the numbers if you expect traffic or plan to take scenic detours — the calculator itself doesn't build this in automatically.
How do I find my car's real mpg?
Trip-computer estimates can run optimistic. The most reliable way is to measure it yourself from an actual fill-up: note your odometer, drive normally until the tank is low, refill to full, and record the gallons added. Our MPG calculator turns those two numbers into your real, measured mpg in seconds — plug that figure in here for a much more accurate fuel cost.
Does gas price vary that much by route?
Yes, often significantly — prices can swing 30 cents or more per gallon between neighboring towns, and even between two stations on the same street. For the most accurate estimate, check a current local average for the area you'll actually be driving through rather than using a national average.