Don't ever knowingly fly with this if you can avoid it -- especially in older planes (DC10s, 727s etc) as cabin pressure adjustment systems weren't as sophisticated as they are in more recent models.   The ear drum could burst.   Any big change in altitude over a short period of time can do the same.   Elevators in very tall buildings, for example.

One thing that often helps ear congestion (as long as it's just temporary congestion)  is to soak towels or paper towels in boiling hot water and then place them in a mug, cup etc.   Let them cool very slightly so there isn't a lot of steam coming off them and then gently place the cup over the ear.   Don't press it right against your head;  what you want is for the warmth and moisture to get inside your ear -- you don't want a complete seal around the ear.   This is a good trick for those times when you have flown with congestion not realizing how bad it is until take-off.  Flight attendants will usually be able to assist.