The government has agreed to change its bill allowing ministers to take maternity leave, so that it uses the term "mother" rather than "person".
The Ministerial and other Maternity Allowances Bill would ensure up to six months' leave on full pay.
But the House of Lords rejected the use of the word "person" in its text.
The government initially argued this was in line with "drafting convention" but has changed its view, saying use of "mother" is legally "acceptable".
The bill was introduced in time for Attorney General Suella Braverman, who is expecting her second child, to take maternity leave this year.
Under existing laws, she would have to resign if she wanted to take time off following the birth.
During a debate on Thursday, Cabinet Office minister Lord True said the government "recognised the strength of feeling" on the use of language in the bill and would change its mind.
Labour leader Sir Keir Starmer has backed the legislation, adding that the change to pregnant minister's rights "should have been brought in a long time ago".
And Prime Minister Boris Johnson has said: "The choice between taking leave to recover from childbirth and care for a new-born child or resigning from office is not acceptable in modern times."
The Ministerial and other Maternity Allowances Bill, already passed by the House of Commons, is expected to enter law soon.