There are plenty of tricks you can use to score cheap flights, from setting price alerts to waiting until Sunday to book your trip. But one of the practices with the biggest payoffs is also one of the most controversial. “Hidden city ticketing,” or booking a flight with the intention of getting off at the layover city rather than the final destination, is perfectly legal, but there are some factors to consider before making it a habit.

According to Business Insider, hidden city ticketing is a sneaky way to save money. Say you want to travel to New York from Orlando. The direct flight costs $350, but a flight to Boston with a stopover at JFK only costs $200. By booking the flight to Boston and simply getting off at New York, you can save significant cash. There’s even an entire travel site called Skiplagged dedicated to finding customers cheap flights this way. But while it can benefit flyers, it’s a problem for airlines, and some have started to crack down on it.

Hidden city ticketing is a violation of most airlines’ contract of carriage, which means they're allowed to punish you if they catch you doing it. These penalties can include forcing you to pay the full price of the trip, confiscating your frequent flyer miles, or preventing you from boarding the plane in the first place.

So if you do plan on taking advantage of hidden city ticketing, it’s important to do so discreetly. Bring any luggage you need into the cabin with you, as any checked bags will end up at the final destination, not the layover city. And book your flights one trip at a time, because if the airline catches on to your scheme they could cancel the second half of your roundtrip flight.

Of course, even if you take extra care to cover your tracks, using the loophole still puts you at risk. There’s always a chance the airline notices when you don’t get off at the intended destination, which could complicate any future plans you make with them. And flights are subjected to last-minute rerouting all the time, so if you buy a ticket with this plan in mind, be prepared to possibly end up in the city printed on your ticket instead.

[h/t Business Insider]