Mileage Calculator
Work out your gas mileage, price the fuel for any trip, and calculate mileage reimbursement at the current IRS rate. Switches between MPG, L/100km and km/L.
Result
25 MPG (US)
350 miles on 14 gallons works out at 25 MPG (US).
MPG (US)
25
MPG (UK)
30.02
L/100km
9.41
km/L
10.63
How it was worked out
350 miles ÷ 14 gallons = 25 MPG (US)
IRS figures follow Notice 2026-10 as revised for travel from 1 July 2026. Employers can pay a different rate, so check your own policy before you file.
One Tool for Fuel, Cost, and Claims
Most mileage questions fall into three buckets: how much fuel the car actually uses, what a drive will cost, and what the miles are worth on an expense claim. Each one has its own tab here, so you are never converting units in your head or hunting for this year’s reimbursement rate.
Why Use This Mileage Calculator?
Every Fuel Unit at Once
Enter a tank in gallons or litres and read the result as US MPG, imperial MPG, L/100km and km/L together. Switching the unit system converts the numbers you already typed.
Real Trip Costs
Price a drive from distance, economy and pump price, with a round trip toggle and a split between passengers. You get total cost, fuel needed, and cost per mile.
Current Reimbursement Rates
IRS business, medical and charitable rates for 2026 and 2025 are built in, alongside the German and Spanish per-kilometre allowances. Any custom rate works too.
The Arithmetic Stays Visible
Every answer shows the formula behind it, so you can paste the working into an expense report or rebuild it in a spreadsheet without guessing.
How this Mileage Calculator works
Three calculations sit behind the tabs, and all of them run on one internal pair of units: kilometres and litres. Whatever you type is converted to that pair first, the arithmetic happens once, and the answer is converted back into the system you selected. That is also why switching from US to metric halfway through carries your numbers with it, instead of leaving a 350 that used to mean miles sitting in a field now labelled kilometres.
Fuel economy divides distance by fuel. The single figure that comes out is then expressed four ways, because MPG and L/100km are inverses of each other: one counts distance per unit of fuel, the other counts fuel per fixed distance. Gallons are the other trap. A US gallon holds 3.785 litres and an imperial gallon holds 4.546, a gap of about 20 percent.
Trip cost turns your economy figure into litres per kilometre, multiplies by the distance, then multiplies by the pump price. Ticking round trip doubles the distance before any of that runs, and the passenger field divides the total at the very end.
Reimbursement is a straight multiplication, so the work is in the rate. The presets carry the IRS business, medical and charitable rates for 2026 and 2025, including the mid-year revision that lifted the business rate from 72.5 to 76 cents on 1 July 2026, alongside the German and Spanish per-kilometre allowances. Editing the rate by hand switches the selector to custom. Nothing you type is uploaded.
How to use this Mileage Calculator
Pick the calculation
Choose fuel economy, trip cost, or mileage reimbursement. Each tab keeps its own figures, so you can move between them without retyping anything.
Set the units and enter your numbers
Switch between miles and gallons, kilometres and litres, or imperial gallons. Anything you have already typed is converted for you.
Read the result and copy it
Under the answer sit the formula and four supporting figures, including MPG, L/100km and km/L side by side.
Example Usage
Pricing a long drive before you set off:
Frequently Asked Questions
How do I work out my real gas mileage?
Why is my calculated MPG lower than the number on the window sticker?
What is the IRS mileage rate for 2026?
Which mileage rate applies if my trip crossed 1 July 2026?
Can I use this for German or Spanish mileage allowances?
How do I convert MPG to L/100km?
Is a US gallon the same as a UK gallon?
Does the trip cost mode account for a return journey?
Should I claim the standard mileage rate or my actual car expenses?
Are my numbers sent anywhere?
Related Tools
Auto Loan Calculator
Work out your monthly car payment, total interest, and payoff date.
Unit Converter
Convert between various units of measurement.
Miles to KM Converter
Convert miles to kilometers distance instantly.
Percentage Change Calculator
Find the percentage increase or decrease between two numbers, work back to the original value, and check percentage difference or percent error.
Income to Debt Calculator
Work out your debt-to-income ratio in seconds. Enter your gross monthly income and loan payments to see the housing and total DTI percentages lenders check.
VDI Cost Calculator
Estimate VDI cost per user and in total. Combine compute, storage, licensing, and support to compare cloud DaaS and on-premises pricing.
The Mileage Calculator is maintained by CodeItBro. We aim to provide the best free developer tools on the web. If you have feedback or suggestions, please visit our contact page.

