By Alex Stevenson Follow @alex__stevenson
Leaders have agreed to scrap the 300-year-old rule which gives males precedence in the royal succession, David Cameron has announced.
The prime minister said he had won unanimous agreement after attempting to persuade representatives of all 16 countries, known as the Queen's realms, which have the Queen as their head of state.
All 16 met on the fringes of the Commonwealth summit in Perth, Australia when Mr Cameron sought permission for the proposed change.
"We will end the male primogeniture rule so that in future the order of succession should be determined simply by the order of birth," the prime minister announced to reporters at a press conference in Perth.
"And we've agreed to introduce this for all descendants from the Prince of Wales. Put simply, if the Duke and Duchess of Cambridge were to have a little girl, that girl would one day be our queen."
Due to "historic reasons" Britain will legislate first to push through the changes. The Queen will pass royal assent to the legislation as usual, the prime minister said. Her private secretary was present at the meeting.
"Attitudes have changed fundamentally over the centuries and some outdated rules just don't make sense to us anymore," Mr Cameron added.
"The idea that a younger son should become monarch ... simply because he's a man - this way of thinking is at odds with the modern countries that we've all become."
A second change to the rules of succession, which bars anyone who marries a Roman Catholic from succeeding to the crown, was also agreed.
The move, previously described as a "historic anomaly" by Mr Cameron, will be implemented through an international group.
The other 15 realms Mr Cameron succeeded in winning over are Antigua and Barbuda, Australia, the Bahamas, Barbados, Belize, Canada, Grenada, Jamaica, New Zealand, Papua New Guinea, Saint Kitts and Nevis, Saint Lucia, Saint Vincent and the Grenadines, the Solomon Islands and Tuvalu.