Middle-ear pressure mismatch
Your middle ear is a sealed air pocket connected to your throat by the Eustachian tube. As the plane climbs, cabin pressure drops while trapped ear air stays at ground pressure โ pushing the eardrum outward. Swallowing opens the tube to equalize.