"We recognise the role of the queen in championing the Commonwealth and its peoples," the Commonwealth leaders said in a statement. "The next head of the Commonwealth shall be His Royal Highness Prince Charles, the Prince of Wales."
There have been calls for the role to be rotated around the 53 member-states, most of which are former British territories, but in recent days the queen, 91, the British government and other leaders have backed Charles, 69.
The Commonwealth evolved out of the British empire in the mid-20th century, and the queen has been its head since her reign began in 1952. Charles had long been expected to take on the role even though it is not strictly hereditary.
The queen, who celebrates her 92nd birthday on Saturday, had made clear her preference for Charles to succeed her.
"It is my sincere wish that the Commonwealth will continue to offer stability and continuity for future generations and will decide that one day the Prince of Wales should carry on the important work started by my father in 1949," she said at the formal opening of the leaders' meeting on Thursday.
Charles himself had also made an informal pitch for the role this week, saying in a speech: "the Commonwealth has been a fundamental feature of my life for as long as I can remember."
This week's London meeting has been widely assumed to be the last that the queen will attend in person. The meetings are only held every two years, the next one is in Rwanda and the monarch has not taken a long-haul flight for several years now as she cuts back on her official duties.
The summit has seen thousands of delegates from across the globe descend on London, debating issues such as the environment, women's rights and trade.
Britain has sought to use its hosting of the event as a chance to reinvigorate the loose alliance of countries, which have a combined population of 2.4 billion people, eyeing increased trade and global influence as it prepares to leave the European Union.
More about: Prince-Charles