Skip to main content
Viralrang

Fuel Cost Calculator

Fuel cost for any drive — distance, MPG, and today’s gas price, with round-trip and per-person split.

Last updated

300 mi
28 MPG

Enter today's local price.

People sharing the fuel bill.

You need

$34.29in fuel

10.71 gallons for 300 mi

Gallons needed
10.71 gal
Distance driven
300 mi

How to use the fuel cost calculator

Enter the one-way distance, your vehicle’s real-world fuel economy, and today’s gas price, and the calculator gives you the fuel cost for the drive. Distance is one way on purpose — flip the round-trip toggle and it doubles the miles for you, so you never have to remember to multiply. Map apps show the driving distance for any route; use that number rather than straight-line miles.

Fuel economy is where estimates go wrong. The MPG on the window sticker is a lab figure; your real number is lower in city traffic, with a loaded car, a roof box, winter gas, or a heavy right foot, and higher on a steady highway cruise. If you track it, use your own average from the trip computer or a few fill-ups. If you don’t, knock 10–15% off the EPA highway rating for a realistic planning number, and more if the route is hilly or stop-and-go.

Gas price is the input that moves day to day and state to state, so enter today’s local price rather than trusting a built-in guess — a 40-cent swing on a long drive is real money, and prices vary that much across a single state line. Check a fuel-price app for your route before you budget; for a multi-day road trip, use the average price along the way, not just the pump near home.

If you’re splitting the drive with others, set the number of people and the calculator divides the fuel cost evenly — handy for settling up on a group road trip or a regular carpool. The split applies to fuel only; tolls, parking, and snacks are their own conversation. For a recurring commute, run it one way with your daily round trip and multiply by the number of days you drive.

The result is fuel only — the gas that goes in the tank. It is not the true cost of driving, which also includes wear, tires, and depreciation (the IRS pegs all-in driving at 72.5 cents per mile (the 2026 IRS rate), several times the fuel-only figure). For comparing a drive against a flight or train, fuel cost is the right number; for understanding what a car really costs you per mile, it’s just the start.

The formula

Fuel cost is three numbers multiplied together, with an optional doubling for the return leg and an optional split at the end:

distance driven = distance × (round trip ? 2 : 1)
gallons = distance driven ÷ MPG
cost = gallons × price per gallon
per person = cost ÷ travelers
Fuel cost flow300 miles divided by 28 MPG is 10.71 gallons, times $3.20 per gallon, is $34.29.DISTANCE ÷ MPG × PRICEdistance300 mi÷economy28 MPG=fuel10.71 gal×$3.20/gal$34.29
Distance over MPG is gallons; gallons times price is the drive.

Worked example with the defaults — 300 miles one way at 28 MPG and $3.20 a gallon: that’s 300 ÷ 28 = 10.71 gallons, times $3.20 = $34.29 in fuel. Flip on round trip and it’s 600 miles, 21.43 gallons, and $68.57. Split that round trip between two people and each owes $34.29.

The quick mental version: gallons is just miles divided by MPG, and cost is gallons times price. Doubling your MPG halves both the gallons and the cost — which is why fuel economy, not price, is the biggest lever on what a long drive costs you.

Frequently asked questions