Free calculatorLive resultsSteps and sourcesEmbed on your site, free

Gas Pricing Calculator

Gas pricing calculator works out Fuel cost and Total trip cost from Distance, Distance unit and Fuel economy. The default figures on this page give fuel price implied of 4.1667; change any entry and the result, the working and the sources update together.

Fuel price implied
4.1667
Fuel Cost and Trip Calculator
Fuel cost
50
Total trip cost
50
Cost per person
50
Fuel needed
12
Fuel needed
12 US gallons
Distance travelled
300
Cost per mile or km
0.1667
Economy in US mpg
25
Economy in L/100km
9.4086
Economy in km/L
10.6286
Worked out from US EPA fuel economy definitions and the mpg to L/100km relationship and 1 other source.

Your figures

Updates as you type
Formatting only. This does not change the calculation.
One-way distance, unless the round-trip option is on.
Ignored when solving for economy.
Used only when solving for the fuel price the trip actually worked out at.

How this is worked out

2 steps
  1. Fuel used = 300 mi / economy = 12 US gallons.
  2. Price paid = 50 / 12 = 4.1667 per US gallon.

Its 9 worked examples are re-run on every release, last on 15 September 2026. What changed

Sources and references

2 sources
US EPA fuel economy definitions and the mpg to L/100km relationship
The exact conversion constant is 235.214583 L-mi per 100 km-gal, from the exact inch and pound definitions.

Keep this result

Save it, change one figure, then compare the two

The calculation stays free. Save this scenario, adjust one assumption, save that too, and put them side by side to see exactly what the change costs you. A free account keeps 5 scenarios and 2 comparisons; Personal makes both unlimited and adds exports and private links. Nothing is saved unless you press Save.

1 · Calculate2 · Save3 · Compare4 · Export5 · Share
Open workspace

What the gas pricing calculator calculates

Computes the fuel needed and its cost for a journey from distance, fuel economy and fuel price, in either US or metric units, and can solve instead for the fuel volume alone, the economy achieved, the distance a tank covers, or the fuel price a known spend implies.

How to use this gas pricing calculator

Enter Distance, Distance unit, Fuel economy and Economy unit. Fuel cost updates as you type. Change one figure at a time to see what drives the result.

How the result is worked out

Open “How this is worked out” beside the result for the step-by-step calculation behind Fuel cost, Total trip cost and Cost per person.

The method follows US EPA fuel economy definitions and the mpg to L/100km relationship and NIST Special Publication 811 for the exact gallon, mile and litre definitions.

What you can compare

Change one input at a time to see how it affects Fuel cost, Total trip cost and Cost per person. The inputs you can vary are Distance, Distance unit, Fuel economy, Economy unit, Price is per and Amount spent on fuel.

Results are general information, not financial, tax, legal, medical or engineering advice. Check any decision that matters with a qualified professional.

Embed this calculator on your website

Copy this code into any page. The calculator appears with the figures currently entered, sizes itself to fit, and a small credit line links back here. Free, no account, no ads inside it, no tracking of your readers. Set your own figures and fixed fields; Personal removes the credit line, sets your colour and shows you which sites use it.

Preview

See something wrong? Report a problem with this calculator

Frequently asked questions

How do I calculate how much my gas will cost?

Computes the fuel needed and its cost for a journey from distance, fuel economy and fuel price, in either US or metric units, and can solve instead for the fuel volume alone, the economy achieved. Open “How this is worked out” beside the result to see each step for your own figures.

Can Google Maps estimate gas cost?

Computes the fuel needed and its cost for a journey from distance, fuel economy and fuel price, in either US or metric units, and can solve instead for the fuel volume alone, the economy achieved. On the figures this page opens with — distance 300 and fuel economy 30 — the fuel price implied is 4.1667. Put your own figures in their place and the working updates beside the result.

What is the easiest way to calculate gas mileage?

It needs Distance, Distance unit, Fuel economy, Economy unit, Price is per and Amount spent on fuel. Nothing else is required, and the figures stay in your browser.

Can Google Maps calculate gas cost?

The result gives Fuel cost, Total trip cost, Cost per person, Fuel needed, Distance travelled and Cost per mile or km, each labelled with its unit so the figure can be read on its own.

What information do I need for the gas pricing calculator?

You need Distance, Distance unit, Fuel economy, Economy unit, Price is per and Amount spent on fuel. The page opens with default figures that give fuel price implied of 4.1667, so you can see the scale before entering your own.

What does this gas pricing calculator show?

It shows Fuel cost, Total trip cost, Cost per person, Fuel needed, Distance travelled, Cost per mile or km, Economy in US mpg and Economy in L/100km, with the working and any warnings for your entries.

Related calculators

View all related calculators10 more