Cost per Mile Calculator: Fuel and Operating Cost

Quick summary: This cost per mile calculator divides your operating costs by the miles you drove in the same period. At $3.50 a gallon and 18 MPG, fuel alone is about 19 cents a mile; add $7,000 of other annual costs over 20,000 miles and the total is about 54 cents a mile. It is not the IRS mileage rate.

Last reviewed November 25, 2026. The formulas are arithmetic from figures you enter. Free tool, no sign-up, and your numbers stay in your browser.

Your first step today

Do this today

Run this calculator with real numbers (a real quote, a real price), not guesses, and save the result in your startup budget.

Start small. Your first goal is $500 a month. That is where I started. — Trent

Get the free Startup Kit

Five free files: a startup checklist (PDF), a one-page business plan (Word and PDF), a full plan template (Word), a financials workbook (Excel), and a startup cost worksheet (Excel). Enter your email and the downloads open on the next page. No credit card.

Free Startup Kit signup

How do you use this cost per mile calculator?

Enter the miles you drove in a period, the fuel price you actually paid, and the vehicle’s average miles per gallon. Then add insurance, maintenance, depreciation or a truck payment, and any other operating costs for the same period. The tool shows fuel cost per mile, other costs per mile, and the total.

What is the cost per mile formula?

Fuel cost per mile = fuel price per gallon ÷ miles per gallon. Other costs per mile = (insurance + maintenance + depreciation or payment + other costs) ÷ miles driven. Total cost per mile is those two figures added together.

Input (example)Result
$3.50 per gallon at 18 MPGFuel = $0.19 per mile
$7,000 of other annual costs over 20,000 milesOther = $0.35 per mile
Fuel plus other costsTotal = $0.54 per mile

The default example uses $3.50 ÷ 18 = $0.1944 per mile for fuel, plus $7,000 ÷ 20,000 = $0.35, for a total of $0.5444 per mile, or $10,888.89 for the period ($3,888.89 fuel + $7,000 other). Change the inputs to match your vehicle. These defaults are an illustration, not a national average and not an official rate.

Is this the same as the IRS mileage deduction?

No. This tool estimates what it costs you to drive, from numbers you enter. The IRS standard mileage rate is a separate optional deduction method. For tax year 2026 the IRS rate is 72.5 cents a mile from January 1 through June 30 and 76 cents a mile from July 1, as shown on the IRS standard mileage rates page (checked November 21, 2026, on the live mileage deduction calculator). Use the mileage deduction calculator if you are estimating that deduction, and confirm the current rate on IRS.gov before you file.

Common mistakes

Mixing miles from one period with costs from another, counting both a loan payment and full economic depreciation for the same vehicle, and treating the IRS standard mileage rate as if it were your actual cost per mile.

Frequently asked questions

How do you calculate cost per mile?

Add fuel cost (miles ÷ MPG × price per gallon) to your other operating costs for the same period, then divide by miles driven. Equivalently, add fuel price ÷ MPG to other costs ÷ miles.

Is this the same as the IRS mileage rate?

No. The IRS standard mileage rate is a tax-deduction figure. This calculator is an operating-cost estimate from your own inputs.

Should I include depreciation and a truck payment?

Use one or the other for the same vehicle unless you have a reason to include both. Depreciation is the drop in value; a payment is cash out the door. Pick the measure that matches the decision you are making.

Can I use this for a trucking or delivery business?

Yes. Enter the miles and costs for the truck or van you are pricing, in the same period. For a business that runs several vehicles, do the math per vehicle or use combined miles and combined costs.

Why don’t you show a national average cost per mile?

There is no official government average that applies to every vehicle and every lane. A published “average” from a private survey would be someone else’s numbers, not yours, and would go stale. Enter the costs you actually incur.

General information, not tax or financial advice. Confirm current IRS mileage rates on IRS.gov if you are claiming a deduction.