Lack of exercise is likely a reason. If he was just sitting on his throne all day and not being active, it would contribute to weight gain. Also, maybe there were too many feasts and celebrations where he ate a lot without any self - control.
Well, it could be that the food in his kingdom became more and more indulgent. With rich and calorie - dense meals constantly available, King Dedede simply couldn't resist. Additionally, he may not have had any kind of dietary plan or restrictions. And without any physical activity to burn off the calories, like hunting or jousting which he might have given up, the weight just piled on.
One possible reason could be overeating. He might have been eating too much of the delicious food available in his kingdom.