A long-haul flight delivers four separable headache mechanisms at once, and they need different countermeasures. Cabin pressure is regulated to no worse than the equivalent of 2,438 metres of altitude — typically 1,800 to 2,400 metres in cruise — which drops arterial oxygen saturation into the low nineties and is the driver behind true airplane headache. Cabin humidity runs between 5 and 20 percent, drier than most deserts, which dehydrates mucous membranes over hours. Crossing time zones misaligns your circadian system from local time, and the body resynchronises at only about one hour per day eastward and one and a half westward. And travel itself brings disrupted sleep, missed meals, alcohol, caffeine shifts and sustained stress. Working out which of these is yours is what makes the difference, because hydration will not fix a circadian problem and a sleep schedule will not fix a pressure one.
Eastward and westward flights create genuinely different problems, and that is the most useful place to start.