LONDON (Reuters) - The Queen waved from her Buckingham Palace balcony to the cheering masses on Tuesday and thanked millions of well-wishers at the end of four days of spectacular Diamond Jubilee celebrations marking her 60th year on the throne.
From the biggest flotilla seen on the River Thames for more than three centuries, a star-studded concert and a horse-drawn procession through the capital to street parties in towns, tiny villages and communities up and down the country, the Queen said the show of public affection had been "a humbling experience".
"It has touched me deeply to see so many thousands of families, neighbours and friends celebrating together in such a happy atmosphere," the queen said in a rare televised address to the nation.
"I will continue to treasure and draw inspiration from the countless kindnesses shown to me in this country and throughout the Commonwealth. Thank you all," she said, standing in front of a framed photograph of grandson Prince William and wife Kate.
Hundreds of thousands of people cheered, sang patriotic songs and waved Union Jack flags outside Buckingham Palace at the finale of festivities for the Diamond Jubilee, only the second to be celebrated by a British monarch.
The 86-year-old beamed at the throng and waved from the balcony of the palace, accompanied by the senior members of her family with one notable absentee - Prince Philip, her husband of 64 years who was taken ill with a bladder infection on Monday.
It was one of the few grand state occasions in her life when he has not been present, taking some of the gloss off what has widely been seen as a triumphant diamond jubilee that has reinforced the popularity of the queen and the monarchy.
The grand Mall avenue leading to the queen's London residence was turned into a sea of red, white and blue as well-wishers flooded the road to hail the queen before a flypast led by the Spitfires which won the Battle of Britain and concluded with a display by a Royal Air Force aerobatics team.
Celebrations outside Buckingham Palace closed when soldiers fired a rifle salute, then thrust their bearskin hats in the air to lead the crowds beyond the gates in a rousing three cheers to the Queen, the only British monarch other than Queen Victoria to have reigned for 60 years.
As the ecstatic crowd roared its approval, the Queen flanked by son and heir Charles, his wife Camilla, Prince William and his new wife Kate as well as brother Harry, gave one final wave before heading inside.
"I don't think we'll see anything like this again in my generation. It was wonderful," said Joseph Afrane, 49, a photographer who was wearing a red, white and blue Union Jack flag waistcoat and hat.
Millions attended street parties, watched the Queen glide past on a gilded barge as part of the River Thames pageant on Sunday, watched a concert in front of Buckingham Palace on Monday and spilled into the streets for Tuesday's carriage procession and balcony wave.
Not even typically British inclement weather dampened enthusiasm, with rain failing to deter the crowds, although Philip's illness overshadowed Tuesday's events.
After visiting him in hospital, the queen's youngest son Prince Edward said his father was getting better.
However, without Philip who has been at her side throughout her long reign, the Queen cut a slightly subdued figure as she attended a thanksgiving service at St Paul's Cathedral and a celebratory lunch.
"The remarkable thing is that she carried on (despite Philip's illness)," said Tim Fell, 32, a nursery school teacher from Edinburgh in Scotland who was carrying a homemade banner reading "Elizabeth the Great: she's a diamond".
"Words like duty, commitment, loyalty and country aren't just words in a dictionary for the queen, they are part of who she is," he added.
Unlike some of the previous days' celebrations, Tuesday's events were more typical of the formal displays of pageantry for which British royalty is known across the globe.
Courtiers in an array of dazzling ceremonial red and golden tunics and mounted soldiers wearing shining helmets and breastplates dating from centuries past when Britain was an imperial power were on show across London.
With Philip absent, the queen led a horse-drawn carriage procession to Buckingham Palace in an open-top 1902 State Landau with Prince Charles and Camilla, while military bands played and a 60-gun salute was fired.
Harry, William and Kate, in an Alexander McQueen dress, followed behind.
Earlier, Elizabeth - dressed in a fine silk tulle outfit, embroidered with tiny mint green star-shaped flowers embellished with silver thread - arrived at Paul's Cathedral to shouts of "God save the Queen" and a trumpet fanfare as she made her way past bowing and curtsying members of the congregation.
Commentators said the church service for Elizabeth, who came to the throne aged 25 in 1952, would hold particular poignancy for the queen who as titular head of the Church of England holds her religious role close to her heart.
"We are marking today the anniversary of one historic and very public act of dedication - a dedication that has endured faithfully, calmly and generously through most of the adult lives of most of us here," said Rowan Williams, the Archbishop of Canterbury and spiritual leader of the Anglican church.
Afterwards the royals enjoyed a lavish lunch at Westminster Hall, the oldest part of the Houses of Parliament and the site for the lying-in-state of her mother, the Queen Mother, after her death in 2002.
The long weekend dedicated to the diamond jubilee has been seen as a success story for the monarchy, their media team and the Queen personally.
Polls suggest the crown and the Queen herself are more popular than they have been for decades, with one suggesting the hereditary monarch was more in touch with her people than Cameron and his ministers.
"While many presidents and prime ministers have come and gone, your majesty's reign has endured," said U.S. President Barack Obama in a glowing congratulatory message.
"May the light of your majesty's crown continue to reign supreme for many years to come."
The younger generation of royals, especially William, Harry and Kate, have become the darlings of the British press, once notoriously hostile to the monarchy as it threatened to implode in the 1990s following marital infidelities and the death of Charles's hugely popular first wife, Princess Diana.
Republicans have been vocal in their opposition during the jubilee but have drawn few obvious signs of public backing, although they hope that apathy to the royals felt by some could turn to hostility when the queen is gone and the less popular Charles becomes king.
If nothing else, commentators said the royals had once again provided Britons, suffering through financial hardships, deep public spending cuts and rising unemployment, an excuse to forget their woes and enjoy a party.
"With the economy and one thing or another, this has just been the most fantastic celebration," said designer Sheree Charalampous, 53, who had made her own crown, strung with pearls, pictures of corgis and a portrait of the queen.
"I really think the monarchy is now back in favour again, which is wonderful. Nobody does this sort of thing like us. It has been an amazing four days, just fantastic."
Additional reporting by Peter Griffiths; Editing by Paul Casciato