In terms of civil aviation flight:
It is more appropriate to have a steady and moderate headwind during take-off and landing. Aircraft use relative airspeed in flight, because the headwind can increase the relative airspeed and reduce the takeoff taxiing/landing distance, which is beneficial to flight safety.
But in the cruise phase, the downwind is better. Our flight time depends on the ground speed. If the speed of the plane remains the same, we can increase the ground speed when the wind is downwind, which will enable us to reach our destination faster. Therefore, it can be seen that some pilots want to contact the controller to change the flight level in order to reach a more suitable flight level during cruising (this is also related to the lighter weight of the aircraft and the smaller lift demand after fuel consumption). In the northern hemisphere, because of the westerlies, flying from Beijing to new york can save one or two hours, saving considerable time, fuel and cost, so it is best to cruise with the wind.
In addition: why do you need to stabilize the headwind when taking off and landing? Because if the change is too fast, wind shear, downward airflow, etc. It will make the plane difficult to control and more prone to accidents.
reference data
Zhihu:/question/24971559/answer/29849163.