One possible cause of constipation is lack of sodium. A healthy amount to get is 4-6 grams/day, which translates to 10-15 g/day of table salt (sodium chloride). This includes salt already present in your food, btw.
I find that these days, whenever I get constipated, it’s because I didn’t get enough salt the day before. The amount of fiber I eat is minimal.