How to Calculate Mileage for Taxes

Quick Answer

Miles you drive for business, charity, medical treatment or a mandatory move as a military service member may be tax deductible. Here are the standard mileage rates for different types of deductible mileage, and how to calculate and claim your deduction.

Woman in a baseball cap driving a car with a delivery box on the back seat

Driving your car costs money. If you drive for business, charity, to receive medical treatment or to move, you may be able to deduct some of your costs on your taxes using standard mileage deductions.

IRS mileage deductions vary, and not all drivers (or driving) are eligible for the deductions. Here, we'll go over what mileage deductions are, the different types of mileage deductions and how to claim these deductions on your tax return. Learning how to accurately calculate mileage for tax purposes can help you reduce your taxable income and save money on your tax bill.

What Is the IRS Gas Mileage Deduction?

The IRS allows you to take a mileage deduction when you drive for certain business, charitable or medical purposes, or if you're an active-duty service member with moving expenses from a mandatory relocation.

The IRS adjusts standard mileage rates for inflation every year. Here are the standard mileage rates for 2024:

  • 67 cents per mile for business use
  • 21 cents per mile for medical or moving purposes by qualified active-duty members of the military
  • 14 cents per mile driven in service of a charitable organization

The same mileage rates apply for electric, hybrid electric and diesel-powered vehicles, including vans, pickup trucks and panel trucks. However, not all mileage is deductible. If you drive your car as an employee, you generally can't deduct mileage on your taxes as an unreimbursed employee expense, with narrow exceptions noted below.

Types of Eligible Mileage

The IRS offers standard mileage rates for business mileage, very limited employee driving, driving for medical care, charity mileage and relocation-related driving for active-duty members of the military. Here's how these break down.

Business Mileage

Business owners, self-employed people and independent contractors who drive their personal vehicles for business can choose to deduct a portion of their actual vehicle expenses or use standard mileage rates to calculate business deductions based on usage.

What qualifies as business use of your personal vehicle? Here are a few examples of business mileage:

  • Driving from one workplace to another
  • Visiting clients or customers
  • Going to a business meeting at a location that isn't yours
  • Getting from your home to a temporary workplace, such as a construction worksite

Among the uses that aren't included in deductible business mileage:

  • Commuting to and from your home to your office, store or other regular place of business
  • Traveling for an overnight trip, which counts as a travel expense rather than business mileage

Select Employees

The Tax Cuts and Jobs Act eliminated employee deductions for unreimbursed expenses except as they apply to a small group of select employees. Armed forces reservists, qualified performing artists, fee-basis state or local government officials, or employees with impairment-related work expenses may use the same standard mileage rate as business owners (67 cents per mile in 2024) to deduct for their work-related miles.

Medical Care

If you are itemizing deductions and are claiming a deduction for medical expenses, you can include 21 cents per mile driven to get to and from medical appointments, plus parking and tolls.

Active-Duty Military

Members of the military who are required to move due to a military order may deduct unreimbursed moving expenses at 21 cents per mile.

Volunteering

If you drive your personal vehicle while volunteering for a qualified charity, you may deduct 14 cents per mile as a non-cash charitable contribution. Your mileage isn't eligible for this deduction if the charity has reimbursed you for mileage or if your travel was primarily for recreation or pleasure.

How to Use the Gas Mileage Deduction

To claim a mileage deduction, you'll need to track and document your mileage, meet IRS requirements for deducting business mileage (if you're a business owner) and claim your deduction using the appropriate tax form.

Documenting Your Miles

Whichever type of mileage deduction you're claiming, the IRS requires a comprehensive and contemporaneous record of your deductible miles. That means creating an ongoing record of the date, destination, purpose of your trip and miles traveled as you go, rather than trying to recreate a record at tax time. You can keep a paper log in your vehicle and use it to record your trips. Or consider using an app to track your mileage.

Claiming Mileage if You're Self-Employed

Business owners can choose to deduct a percentage of actual vehicle expenses or deduct for business mileage using the standard mileage rate. However, to use the standard mileage rate and claim a deduction for business use of your personal car, you need to meet a few IRS requirements, including the following:

  • You must own or lease the car.
  • You must use the standard mileage deduction in the first year you place the vehicle into service. You can switch to using actual expenses in the following years if you own the car.
  • If you lease and choose the standard mileage deduction, you have to use standard mileage for the entire lease term.
  • You may not operate five or more cars at the same time.
  • You must not have claimed depreciation on the car using a method other than straight-line depreciation.
  • You must not have claimed a Section 179 (immediate expense) deduction on the car.
  • You must not have claimed the special depreciation allowance on the car.
  • You must not have claimed actual expenses after 1997 on a car you lease.

How to Claim Mileage Deductions

Different mileage deductions require different tax forms. The table below shows types of mileage, who (or what) is eligible, standard rates for 2024 and how to report your miles to claim the deduction on your Form 1040 tax return.

Deducting Mileage on Your Tax Return
Type of MileageEligibility2024 Standard Mileage RateHow to Report
Business mileageBusiness owners, self-employed people, independent contractors67 cents per mileComplete Part IV on Schedule C (Form 1040); enter the result on Part II, line 9
Work-related mileage for select employeesArmed forces reservists, qualified performing artists, fee-basis state and local government officials, employees with impairment-related work expenses67 cents per mileCalculate eligible miles using Form 2106 and enter results on Schedule 1 (Form 1040), line 12
Medical milesMiles traveled to receive medical, dental or therapeutic treatment21 cents per mileInclude in total medical expenses on line 1, Schedule A (Form 1040)
Moving expensesActive-duty military service members ordered to move residences21 cents per mileUse Form 3903 to calculate your eligible moving expenses and add the result to line 14 on Schedule 1 (Form 1040)
Charity milesMiles driven while volunteering for an IRS-qualified charity14 cents per mileInclude mileage deduction in non-cash contributions: line 12, Schedule A (Form 1040)

The Bottom Line

Although calculating and claiming mileage deductions is relatively straightforward, handling taxes and recordkeeping for your small business or side gig, or itemizing deductions for charity or medical expenses, can be complex. Tax preparation software—backed up by accounting software, if you have a business—can help you keep your information straight and your tax deductions in order. If you need more help, contact a qualified tax pro for additional advice.