The changes would also allow heirs who marry Roman Catholics to inherit the throne.
"We will end the male primogeniture rule so that in future the order of succession should be determined simply by the order of birth," Cameron said after talks with the 15 other realms with the queen as head of state.
"We have agreed to scrap the rule which says that no one that marries a Roman Catholic can become monarch," Cameron added at a press conference.
Cameron has the political support to make the changes in Britain but required the agreement of the 15 other Commonwealth realms, including Canada, Australia, New Zealand and smaller nations in the Caribbean and the Pacific.
There has been a reluctance to press the issue in the past due to the legal complexities and concern that tinkering with the rules may encourage republican movements.
But the debate was intensified by the April wedding of William, the second in line to the throne, while the celebrations for Queen Elizabeth's 60 years as monarch next year may also be a chance to rally support.