Fuel Cost Calculator
Test cases replayed : 2 of 2 match · Methodology · No outside source listed
Enter the distance, your car's fuel economy and the gas price.
Result
Fuel cost
Fuel used (gallons)
- Cost per mile
Estimate for planning only, not tax, legal, financial or medical advice. This calculator uses the method explained on this page.
This browser did not allow copying. The sentence is in the box below, already selected: copy it with your keyboard or the menu.
How to use this calculator
Fill in the fields in this order; each step takes you to its field.
- Distance, in mi: enter 0 or more.
- Fuel economy (miles per gallon): enter 1 or more.
- Gas price ($ per gallon): enter 0 or more.
- Read the result: Fuel cost; the panel also shows Fuel used (gallons) and Cost per mile.
How this calculator works
Gallons = miles ÷ MPG. Fuel cost = gallons × price per gallon. Cost per mile = price ÷ MPG.
The formula
| Symbol | Meaning | Unit |
|---|---|---|
| Distance | mi | |
| Fuel economy (miles per gallon) | ||
| Gas price ($ per gallon) | ||
| Fuel used | gallons | |
| Fuel cost | $ |
Worked example
| Distance | 300 mi |
|---|---|
| Fuel economy (miles per gallon) | 28 |
| Gas price ($ per gallon) | 3.2 |
| Fuel used (gallons) | 10.71 |
|---|---|
| Cost per mile | $0.11 |
Fuel cost $34.29
Each step uses the unrounded value of the step before it; figures on this page are rounded for display.
Frequently asked questions
How do I calculate gas cost for a trip?
Divide the miles by your MPG and multiply by the gas price: 300 miles at 28 MPG and $3.20 a gallon costs $34.29.
Where do I find my car's MPG?
On fueleconomy.gov or the window sticker; your real figure from a fill-up is more accurate.