When you’re traveling, it’s all too easy to rack up unexpected expenses. You might have mastered the tricks for saving money when you’re on vacation—but what about ways to save money when you’re still en route? Lifehacker reports that the website TravelMath now helps travelers decide whether it's a smarter financial choice to fly or drive to their destination.

When making its calculations, TravelMath considers airplane ticket costs and gas prices, the number of travelers, the cost of hotels for multi-day road trips, fuel efficiency, and even the price of wear and tear on your vehicle. It also allows users to input their hourly income in order to determine how much money they might lose while taking unpaid time off to travel.

Some of the recommendations TravelMath makes are relatively intuitive. For instance, unless you’re making a whole lot of money, it’s almost always wiser to drive between relatively close cities like Boston and New York. Things get trickier, however, when you’re traveling longer distances or with more people. If you’re traveling solo from New York City to Seattle, for example, it makes more financial sense to fly. But if you’re traveling with the whole family, the website shows you can save several hundred dollars by taking a road trip.

While these are all calculations a savvy traveler could likely make on their own, TravelMath is a quick tool for jump-starting your travel plans. By lining up all of the travel costs of flying and driving side by side, the website makes choosing the cheapest transportation option simple.

[h/t Lifehacker]