The types of moving expenses you can deduct fall into two general categories:
Moving your household goods and personal effects, including in-transit or foreign-move storage.
Traveling (including lodging but not meals) to your new home.
The expenses must be reasonable and travel must be by the shortest, most direct route by conventional transportation. Costs for stopovers or side trips cannot be deducted. You can deduct moving expenses for yourself and members of your household.
Moving household goods and personal effects
You can deduct:
the cost of packing, crating and transporting your household goods and personal effects and those of the members of your household,
the cost of in transit storage,
any costs of connecting or disconnecting utilities,
the cost of shipping your car and household pets, and
the cost of moving household goods and personal effects from a place other than your home, up to the amount it would have cost to ship them from your former home.
In-transit storage includes the cost of storing and insuring your household goods and personal effects for up to 30 days, after they are moved from your former home and before they are delivered to your new home.
Travel expenses
You can deduct the reasonable cost of transportation and lodging for one trip, for yourself and members of your household, from your old home to your new home. You do not all have to travel together or at the same time. You can deduct lodging expenses for one day in the area of your old home, after you could no longer live in your home because everything was packed. Meal expenses are not deductible.
If you travel by car, you can deduct either your actual expenses for gas and oil, if you keep adequate records, or you can take the standard mileage rate (cents per mile, as published by the IRS each year). In either case, you can also deduct parking and tolls, but not general repairs and maintenance on your car, insurance, or depreciation.