Cost Gas Calculator
Fuel Cost and Trip Calculator works out Fuel cost and Total trip cost from Solve for, Distance and Distance unit. The default figures on this page give total trip cost of 35; change any entry and the result, the working and the sources update together.
Your figures
Updates as you typeHow this is worked out
2 steps
- Fuel needed = 300 mi / economy = 10 US gallons.
- Cost = 10 x 3.5 = 35.
Its 9 worked examples are re-run on every release, last on 15 September 2026. What changed
Sources and references
2 sources
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.
What the Fuel Cost and Trip 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 Fuel Cost and Trip Calculator
Enter Solve for, Distance, Distance unit and Fuel economy. Fuel cost updates as you type, and “Use a worked example” loads checked figures you can adjust. 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.
300 miles at 30 mpg and 3.50 a gallon example
With Distance: 300, Fuel economy: 30, Fuel price: 3.5, Solve for: cost, the calculator returns Fuel needed: 10, Fuel cost: 35. This example is checked against an independent source in the test suite.
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 Solve for, Distance, Distance unit, Fuel economy, Economy unit and Fuel price.
Results are general information, not financial, tax, legal, medical or engineering advice. Check any decision that matters with a qualified professional.
See something wrong? Report a problem with this calculator
Frequently asked questions
Can Google Maps calculate 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. Open “How this is worked out” beside the result to see each step for your own figures.
How do I calculate the cost of fuel for a trip?
It needs Solve for, Distance, Distance unit, Fuel economy, Economy unit and Fuel price. Nothing else is required, and the figures stay in your browser.
How many miles is $20 of gas?
On the figures this page opens with — distance 300, fuel economy 30 and fuel price 3.5 — the total trip cost is 35. No single number fits everyone: change any figure above and the answer updates as you type, with each step of the arithmetic beside it.
How can I calculate the cost of gas for a trip?
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 Fuel Cost and Trip Calculator?
You need Solve for, Distance, Distance unit, Fuel economy, Economy unit, Fuel price, Price is per and Fuel used. The page opens with default figures that give total trip cost of 35, so you can see the scale before entering your own.
What does this Fuel Cost and Trip 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.
