Skip to content
GasBudgeter logo
$4.28/gal

Gas Cost Calculator: Estimate Your Trip Fuel Cost in Seconds

The average American household spends about $3,120 a year on gasoline(U.S. Bureau of Labor Statistics), yet most of us only find out what a trip costs after we've paid for it. Enter three numbers (distance, your car's MPG, and the price per gallon) and see gallons needed, total trip cost, and cost per mile before you turn the key.

📍
miles
🚗
mpg
⛽
$/gal

Driving several stops? Plan the whole route in the Trip Planner →

U.S. National Average

$4.28/gal

EIA week of
October 19, 2026

Prices come from the U.S. Energy Information Administration (EIA.gov) and update weekly. See how we source our data →

How the gas cost calculator works

No black box here. Say you're driving 400 miles from Dallas to Houston and back in a car that gets 32 MPG, with gas at an example price of $3.96 a gallon. You'll burn about 12.5 gallons, spend roughly $49.50, and pay just over 12 cents per mile. That's the whole calculation, and it works the same for a daily commute, a delivery route, or a cross-country road trip.

One honest caveat: your window-sticker MPG is optimistic. Real-world fuel economy typically runs 10 to 15% lower in city traffic, cold weather, or hilly terrain. If you want a tighter estimate, calculate your actual MPG from your last fill-up. Our MPG calculator does it in one step, and the cost per mile tool adds maintenance and depreciation.

Worked example

400 miles ÷ 32 MPG = 12.5 gallons
12.5 gallons × $3.96 = $49.50

The formula is trip cost = (distance ÷ MPG) × price per gallon, the same one the U.S. Department of Energy uses. Cost per mile is just $49.50 ÷ 400 miles ≈ 12.4¢. The $3.96 price is only an example; the calculator above starts from this week's EIA average.

More examples at fixed example prices
TripMilesMPGPrice/galGallonsFuel costPer mile
Weekend road trip30030$3.5010$35.0011.7¢
Daily commute4025$4.001.6$6.4016.0¢
Long drive in a larger SUV52020$4.2526$110.5021.3¢

Today's gas prices, straight from the EIA

A calculator is only as good as the price you feed it, and prices swing hard by state. California drivers routinely pay over a dollar more per gallon than drivers in Texas or Mississippi. We maintain a price page for every state, built on the EIA's weekly retail survey and refreshed when each week's figures come out.

Planning a multi-state trip? See the cheapest states for gas to time your fill-ups, or check price trends since 2020.

2026 IRS mileage rates, built into our tax tools

Driving for work? The IRS raised the business mileage rate to 76¢ per mile for miles driven from July 1, 2026 (Announcement 2026-11), up from 72.5¢ for January to June. Our reimbursement and deduction calculators have both 2026 rates: pick when the miles were driven and the right rate is applied.

The IRS rate covers more than fuel. It bakes in depreciation, insurance, and maintenance, which is why 76¢ a mile is about five times the 14¢ a mile a 25 MPG car spends on gas at an example $3.50 a gallon, and why freelancers and delivery drivers leave money on the table when they only track fuel receipts.

Reimbursement calculator · Business deduction · 2026 rate explained

Source: IRS Notice 2026-10 (January 1 to June 30, 2026) and Announcement 2026-11 (from July 1, 2026)
PurposeFrom Jul 1, 2026Jan to Jun 20262025
Business76¢/mi72.5¢/mi70¢/mi
Medical23.5¢/mi20.5¢/mi21¢/mi
Moving (qualified military)23.5¢/mi20.5¢/mi21¢/mi
Charitable14¢/mi14¢/mi14¢/mi

EV vs gas: which is cheaper where you live?

The answer genuinely depends on your state. Cheap electricity plus expensive gas makes an EV a clear win in some states; in others, the gap nearly closes. Our comparison tools put your state's electricity rates and gas prices side by side and show the real cost per mile for each.

20+ free driving cost tools

Every tool runs in your browser, requires no sign-up, and shows its formula. Start with the one that matches your situation.

Mileage & tax tools

Where this estimate can miss (and how to fix it)

We'd rather tell you the limits than pretend there aren't any. Three things move your real cost away from the estimate:

Your MPG inputEPA figures assume ideal conditions. Use a recent tank-to-tank measurement instead.
Price changes en routeOn long trips, average the price at your origin and destination; it keeps the estimate honest.
Everything that isn't fuelTolls, parking, and wear aren't in a fuel estimate. For total per-mile cost, use the cost per mile tool.

Who's behind GasBudgeter

GasBudgeter is an independent set of driving cost tools. Every price on this site traces to a named public source (gas prices from EIA.gov, mileage rates from IRS.gov), and our Methodology and Sourcespages document how each number is pulled and when it was last refreshed. We don't sell fuel cards, insurance, or leads, so we have no reason to nudge your numbers.

Calculations reviewed by James Hunt

Methodology · Sources · About

Frequently asked questions

How accurate is a gas cost calculator?
It's an estimate, not a receipt. The math itself is exact (distance ÷ MPG × price), but real-world MPG runs 10 to 15% below the EPA label in stop-and-go traffic, hills, or cold weather. Enter your own observed MPG for the closest number.
Where do your gas prices come from?
Weekly retail price data published by the U.S. Energy Information Administration (EIA.gov), refreshed on our site soon after EIA publishes each week's figures. Our Methodology page explains exactly how each figure is sourced and when it was last updated.
What is the 2026 IRS mileage rate?
It depends on when the miles were driven. From July 1, 2026: 76¢ per mile for business and 23.5¢ for medical and qualified moving mileage. The IRS raised those on July 1 because of higher fuel prices; from January 1 to June 30 they were 72.5¢ and 20.5¢. Charitable mileage stays at 14¢ all year. Our reimbursement calculator lets you pick the period your miles were driven in.
How do I calculate gas cost for a trip?
Divide your trip distance by your vehicle's MPG to get gallons needed, then multiply by the price per gallon. A 400-mile trip at 32 MPG and $3.96/gal costs about $49.50. Or skip the math and just enter three numbers above; we'll do it for you.
Should I use city or highway MPG?
Use the figure that matches most of the drive. Highway MPG fits a long interstate trip; city MPG fits a commute with lights and traffic. For a mix, use the EPA combined figure, or better, your own tank-to-tank average, since it already reflects how and where you drive.
Can I compare two cars for the same trip?
Yes. Keep the distance and gas price the same and run the calculator once with each car's MPG. On a 300-mile trip at $4.00 a gallon, a 35 MPG car uses about 8.6 gallons ($34) and a 22 MPG SUV about 13.6 gallons ($55), so the gap is about $20 every time you make that drive.
Should I use national or local gas prices?
Local. State averages can differ from the national figure by more than a dollar per gallon. Use our state pages to find your local average, then plug it into the calculator.
What if I don't know my car's MPG?
Check the EPA fuel economy label, your owner's manual, or your trip computer. Better yet, fill the tank, reset the odometer, drive normally, refill, and divide miles by gallons. That's your real MPG, and it's usually the most honest number.
Is mileage reimbursement the same as fuel cost?
No. Fuel is only part of it. The IRS rate also covers depreciation, insurance, maintenance, and tires, which is why the 76¢ business rate is far higher than the 14¢ a mile a 25 MPG car spends on gas at an example $3.50 a gallon.
Can I compare EV charging with gas costs here?
Yes. Our EV vs Gas tool compares per-mile fuel cost against per-mile charging cost using your state's electricity and gas prices, so you can see which drivetrain is cheaper where you actually live.

Know your trip cost before you drive

Enter your distance, MPG, and local gas price in the calculator above, or jump straight to your state's live prices and start from a number you can trust.

From the blog

Guides, tips, and explainers on fuel costs and mileage

View all →