If you’ve ever noticed that your feet look and feel unusually swollen when you’re flying, you’re not alone. Feet swelling while flying is pretty common, and according to Nelya Lobkova, DPM, a podiatrist based in New York and founder of Step Up Footcare, it’s due to your feet being down for extended periods without movement. “The muscles in our legs aren’t working, and the veins in our lower body need to work harder to get the blood back towards the heart,” she explains. “When the blood pools on the veins, it cause swelling—literally, fluid build up—in the legs.”

Thankfully, there’s an easy solution for this: foot exercises, which help pump blood back up to the heart, thus reducing foot swelling. Below, Dr. Lobkova shares five easy foot exercises you can do throughout your next flight, especially toward the middle and end, which is when she notes most of the swelling tends to occur.

1. Draw the alphabet

“This exercise activates the muscles and tendons in the leg,” Dr. Lobkova says. “When the muscles are activated, they compress against the veins and help push the venous blood up toward the heart.” She adds that this exercise also helps mobilize the ankle joint, which helps with joint stiffness.

To do it, extend one leg in front of you while seated. Keep the foot hovered over the ground (this requires engaging your quad), then begin to draw the alphabet with your big toe. Take breaks if your leg gets tired. Once you get to Z, repeat with the other leg.

2. Flex and point

For this exercise, extend your legs in front of you while seated. Then point and flex each foot 12 times. Repeat for three sets with a 10-second break in between. This foot exercise is highly effective because it specifically works the calf muscle. “This is the biggest muscle in the legs, and the biggest vein in the leg is deep [inside] the calf muscle,” Dr. Lobkova says. “Thus activating the calf muscle has the strongest effect to compress the leg vein and help pump blood up toward the heart.”

3. Seated heel lifts

This too will activate your calf muscles, Dr. Lobkova says. Here’s how to do it: While seated on the plane, lift and lower your heels off the ground 12 times. Take a 10-second break and then repeat the same process three more times.

4. Flexor activation

You’ll need to slip your socks off for this one and do it barefoot. Place a piece of paper or pen on the floor in front of you. Then curl your toes to grasp the pen or paper and lift it off the ground. Do this 12 times with each foot. Then repeat for three sets with a 10-second break in between. “This exercise activates the intrinsic muscles of the foot, which compresses the same vein [as the calves] at the level of the foot,” Dr. Lobkova says. “In turn, although it is a smaller muscle and will have a smaller effect, it will help pump fluid out of the foot and toward the heart.”

5. Walk back and forth

Lastly, Dr. Lobkova suggests walking up and down the aisles in the cabin two or three times. “Standing and walking, as well as light stretching, during a flight wakes up the muscles around the veins to pump harder and help push the blood flow back up toward the heart,” she says. In particular, she advises giving the calf muscles a good stretch while you’re up. Remember, the calf muscle is the biggest muscle in the legs, so stretching it will be most effective in helping reduce foot swelling while flying.

Wearing compression socks also helps prevent foot swelling during flights

In addition to the above foot exercises, Dr. Lobkova recommends wearing compression socks while flying. “Compression socks are special socks meant to deliver a level of compression to the lower extremity, measured in mm of Hg,” she says. “The higher the mm of Hg, the more compression delivered to the legs and feet. Compression aids in preventing edema or swelling in the legs.”

She suggests knee-length compression socks that are 15–29 mm of Hg to help prevent swelling. Just be sure you buy ones that measure your calf circumference. With your new compression socks and the above foot exercises, your feet swelling while flying will be a thing of the past.