CalculateItNow home

Fuel Cost Calculator

Estimate a trip's gas cost from distance, your MPG or L/100 km and the price per gallon or liter — with fuel needed, cost per mile and the split per passenger.

Fuel Cost Calculator: with the default inputs, trip fuel cost is $35.00.

$
Try an example
Trip fuel cost
$35.00
Fuel needed
10 gal
Cost per person
$35.00
Cost per mile
$0.117
Cost per km
$0.072
Economy as L/100 km
7.84
Assumptions
  • Fuel economy is constant over the whole trip.
  • Price per gallon means the US gallon (3.785 L); choose per liter for metric pricing.
  • Only fuel is costed — no tolls, parking, or wear.
What this trip would cost in a more or less efficient car
$0$20$40$601520253035404550mpg (US)
Trip cost
Cost of this trip at other fuel prices (30 mpg (US))
Price per gallonTrip costPer mile
$2.50$25.00$0.083
$3.00$30.00$0.100
$3.50$35.00$0.117
$4.00$40.00$0.133
$4.50$45.00$0.150
Math verified by automated testsUpdated 2026-09-082 sources cited

How this is worked out

The formula

L/100 km = 235.215 ÷ mpg (US)  |  282.481 ÷ mpg (UK)  |  100 ÷ km/L
fuel (L) = distance (km) × L/100 km ÷ 100
trip cost = fuel (L) × price per liter      (price per US gallon ÷ 3.785 = price per liter)
cost per mile = trip cost ÷ miles

Open How it’s calculated above to see this worked through with your own numbers.

What you enter

Trip distance
A number.in mi, km · 0 or more · defaults to 300
Round trip (double the distance)
Turn this on or off.defaults to off
Fuel economy
A number.from 0.1 to 1000 · defaults to 30
Economy unit
Choose one of 4 options.mpg (US gallon) · mpg (UK/imperial gallon) · L/100 km · km/L
Fuel price
A number.in dollars · 0 or more · defaults to 3.5
Price per
Choose one of 2 options.US gallon · liter
People sharing the cost(under More options)
A number.from 1 to 100 · whole numbers only · defaults to 1

What you get back

Trip fuel costmain answer
Fuel needed
Cost per person
Cost per mile
Cost per km
Economy as L/100 km

What this assumes

  • Fuel economy is constant over the whole trip.
  • Price per gallon means the US gallon (3.785 L); choose per liter for metric pricing.
  • Only fuel is costed — no tolls, parking, or wear.

About this calculator

Enter how far you're driving, your vehicle's fuel economy and the local price of fuel, and the calculator returns the trip's fuel cost, how many gallons or liters you'll burn, the cost per mile and — if you're carpooling — each person's share.

How to use it

Distance can be in miles or kilometers; tick round trip to double it. Fuel economy accepts US mpg, UK (imperial) mpg, liters per 100 km or km per liter, and the price can be per US gallon or per liter — mix and match freely, the conversions are done for you. For an honest estimate use your car's real-world economy (many trip computers can display it) rather than the window-sticker number, which is typically 10–20% optimistic on the highway with a loaded car.

Reading the results

Trip fuel cost is the headline. Fuel needed helps plan stops: a 14-gallon tank at 30 mpg gives about 400 miles of range, and running below a quarter tank in remote areas is asking for trouble. Cost per mile is the number to use when reimbursing a friend for a ride or comparing driving against flying or the train. The table shows how the trip cost moves with the fuel price so you can see what a 50¢ swing at the pump does.

US vs. UK gallons

A UK gallon is 4.546 liters and a US gallon 3.785 liters, so the same car scores about 20% higher in UK mpg. If you're reading economy from a British review of your car, select the imperial option or your cost will be understated.

Why L/100 km is the better unit

Miles per gallon is a rate of distance per fuel, so improvements are non-linear: going from 15 to 20 mpg saves 1.67 gallons per 100 miles, but going from 40 to 50 mpg saves only 0.5. Liters per 100 km — the standard everywhere outside the US and UK — measures fuel per distance, so it adds and compares sensibly. The calculator converts everything to L/100 km internally and shows that figure too.

What's not included

Tolls, parking, tyre wear, depreciation and maintenance. The IRS standard mileage rate (roughly 65–70¢ per mile in recent years) is a reasonable proxy for the total cost of driving, of which fuel is usually a third to a half.

Frequently asked questions

How do I calculate the cost of gas for a trip?

Divide the distance by your car's mpg to get gallons, then multiply by the price per gallon. 300 miles ÷ 30 mpg = 10 gallons × $3.50 = $35.

How much does it cost to drive one mile?

Fuel alone: price per gallon ÷ mpg. At $3.50 and 30 mpg that's 11.7¢ per mile. Add wear, tyres, insurance and depreciation and the all-in cost is several times higher — the IRS mileage rate is a good all-in benchmark.

How do I convert mpg to L/100 km?

Divide 235.215 by the US mpg figure (or 282.481 by UK mpg). 30 US mpg is 7.84 L/100 km; 40 mpg is 5.88.

Should I use highway or combined mpg?

For a long trip mostly on motorways, highway mpg is closer, but subtract 10–15% for speed above 70 mph, roof boxes, headwinds and a full load. For mixed driving use combined.

How do I split gas money fairly?

Divide the trip fuel cost by the number of people, including the driver. Set 'People sharing the cost' under More options; if the driver should be exempt, enter passengers only.

Put this calculator on your own site

A working fuel cost, free for any site, with no ads and no sign-up. It resizes to fit wherever you paste it and updates itself as this page improves.

Paste this anywhere. It works on any site, carries no ads, never expires, and always shows the current version.

Fuel Cost Calculator by CalculateItNow

The page's own title. The clearest description of what the link leads to.

The credit line sits outside the widget on purpose, so it is a real link on your page rather than one buried in a frame. Please keep it — it is what pays for CalculateItNow staying free and ad-free. The script only resizes the widget to fit its contents; drop it and the widget still works.

Browse every calculator widget·How to add it to WordPress, Squarespace or Wix

The questions people ask next to a fuel cost.

All everyday calculators·Browse everything