Ex-Labour minister MP Yvette Cooper has revealed that she felt "cut off" by Whitehall officials when she took maternity leave for a second time.
Ms Cooper, who is now the shadow home secretary, told BBC Radio 4's Woman's Hour that communities department staff had been "very unsupportive".
The MP for Normanton, Pontefract and Castleford added she had to "fight" to keep in touch with developments.
Ms Cooper, married to shadow chancellor Ed Balls, has three children.
She rose to work and pensions secretary in Gordon Brown's government, serving before that as a health minister and planning minister.
Ms Cooper told Woman's Hour of her experience after childbirth in 2004: "The second time I took maternity leave from being a minister, which was actually my third child, was actually very hard.
"The first time I took maternity leave as a minister, the Department of Health was really supportive. The second time was the communities department, which was very unsupportive at the time."
Ms Cooper added: "A lot of it comes down to attitudes of civil servants. Whereas the health department had been really helpful about making sure I had support, making sure I was kept in touch with things that were happening, so that it would be very easy to come back in, in the communities department they almost tried to cut me off completely from everything.
"And so it became a bit of a fight, and not wanting me to see any papers while I was away. You end up having to have a bit of a fight about it throughout. That is quite a stressful thing to do when you're on maternity leave.
"Lots of people will know the experience. When you're on maternity leave, you're trying to manage with a new baby. Feeling like you've got to have a fight at work for yourself can be a really hard thing to do."
'Up to date'
Ms Cooper, who married Mr Balls in 1998, was the first UK minister to take maternity leave.
She added that the former Cabinet Secretary, Gus O'Donnell, had reformed Whitehall maternity leave policy since her experience.
Government departments are obliged to keep employees on maternity leave regularly "up to date" with information during their absence and staff can work up to 10 days during their leave in agreement with their employer.
MPs, as self-employed office holders, are not entitled to any specific provision for maternity leave or paternity leave. They can choose how much time to take off and over what period.
David Cameron and Ed Miliband have both taken paternity leave in recent years.
Woman's Hour will be broadcast on Tuesday, 16 August from 10:00 BST. It can be accessed later via the BBC's iPlayer.