Here’s the secret to scoring cheap flights for July 4.

Best Time to Book July 4 Travel
Credit: Getty Images/Aurora Creative

Memorial Day may be right around the corner, but it’s already time to start looking at your next summer vacation. According to troves of historical data, it’s time to start booking your flights for the Fourth of July if you want to score major savings.

Even if you don’t plan on calling out sick on Monday, July 3, you can still celebrate America’s birthday with a quick trip the weekend prior. To determine the best time to book a vacation for the weekend leading up to July 4, we asked the trip booking site Skyscanner to analyze last year’s flight prices.

Based on outgoing flights booked between Thursday, June 30 and Saturday, July 2, and return flights between Sunday, July 3 and Tuesday, July 5 in 2016, Skyscanner determined that the week of May 22 is the earliest opportunity to enjoy savings on air travel. Reservations made this week could result in savings up to 6.79 percent.

If you’re too busy making last-minute arrangements for Memorial Day weekend (don’t worry, us too), you’re in luck. The week of Memorial Day — between May 29 and June 4 — has the best potential for flight deals. Travelers have the potential to save up to 9.55 percent on flights booked this week.

And if you’re a chronic procrastinator, here’s the date to keep in mind: June 26. Travelers who wait to book until the last week of June could save a cool 2.7 percent on flights for the weekend before Independence Day.

So where should you book those cheap airline tickets to anyway? Some of the nation’s best July 4 celebrations (fireworks, free concerts, and hot dog eating contests) take place in New York City, Boston, New Orleans, and the patriotic towns of Boulder, Colorado, Sonoma, California, and Myrtle Beach, South Carolina.