Image caption The Olympic flag was passed on to the mayor of Rio de Janeiro, which will host the Games in 2016

The "spirit of generosity" demonstrated by British people during the London 2012 Olympics has been hailed by Games chief Lord Coe.

The public mood was his highlight of the Games, which ended with a musical closing ceremony and the handover to the next host city, Rio de Janeiro.

The Olympic flag arrived in the Brazilian city on Monday night, marking the start of its preparations for 2016.

Meanwhile, the chairman of the British Olympic Association is to step down.

Having helped to steer Team GB to 29 golds and third place in the medal table at the London 2012 Olympics, Lord Moynihan wrote to the BOA executive board and the National Olympic Committee to confirm his decision.

Image caption Brazilian athletes were among those to greet the Olympic flag upon its arrival in Rio

He plans to remain as chairman until an election is held in November to find his successor.

Earlier, speaking at a press conference, the chairman of Games organisers Locog Lord Coe looked forward to the Paralympics, which will start on 29 August.

He said the Paralympics, first held in the UK in 1948, were "coming home".

Lord Coe predicted that people would be "amazed" by the "quality of sport they see" there.

"This is going to be an extraordinary moment for us," he added, saying his team was focusing on the transition process of moving from the Olympics to the Paralympics.

'With grace'

Lord Coe drew particular attention to those he felt were responsible for the successful running of the Olympic Games.

He thanked the athletes for creating "moments of heroism and heartbreak", the spectators for their "spirit of generosity" and the volunteers for being the "best ever".

"Our volunteers have been sensational. They've had boundless enthusiasm, goodwill, humour - they've done it with grace. And they have in large part been the face of these Games," he said.

It comes after the London 2012 Olympics ended with a spectacular musical closing ceremony and the official handover to the next host city, Rio de Janeiro.

Media playback is unsupported on your device Media caption Lord Coe did not do the 'Mobot', but Mayor Boris Johnson was happy to oblige

Figures from the BBC revealed that 26.3 million people in the UK watched the closing ceremony, compared with 27.3 million people who watched the opening ceremony on 27 July.

The corporation said the Olympics had become the biggest national TV event since the current measurement system began in 2002, with 90% of the population (51.9 million) watching for least 15 minutes.

The most watched athletic event was Usain Bolt's victory in the 100m final, with 20 million people tuning in on 5 August.

In other developments:

Sunday's three-hour closing ceremony featured some of the biggest names of British pop from decades past, including the Spice Girls, George Michael and Elbow.

During the ceremonial part of the show, the Olympic flag was waved aloft by London Mayor Boris Johnson and passed by President of the International Olympic Committee, Jacques Rogge, into the hands of the Mayor of Rio, Eduardo Paes.

The flame at the Olympic Stadium was then extinguished.

Mr Johnson admitted to a "momentary mad desire" not to hand the flag over to Mr Rogge.

Media playback is unsupported on your device Media caption The London 2012 Olympics closing ceremony got off to a spectacular start

He told journalists he felt "sadness that it's over", as well as a sense of relief that the Games had ended.

"Thankfulness that it's all over, but in a good way," he said.

The closing ceremony was watched in the stadium by the 10,000 athletes and 80,000 spectators, along with 26 million British TV viewers.

Mr Rogge, who declared the Games of the 30th Olympiad closed, said: "We will never forget the smiles, the kindness and the support of the wonderful volunteers, the much-needed heroes of these Games," he said.

He went on: "You, the spectators and the public, provided the soundtrack for these Games.

"Your enthusiastic cheers energised its competitors and brought a festive spirit to every Olympic venue."

The Games ended with the US topping the final medal table with 46 golds, followed by China with 38 golds. GB came third with 29 golds - their best tally since 1908.