The "powerful identities" of the capital and the northern English city had shone through after militant attacks as well as a devastating fire that destroyed the residential tower block Grenfell Tower in London, the Queen said.
The 91 year-old monarch, whose televised address is an essential part of a traditional Christmas in Britain, said it had been a privilege to visit victims of the bomb attack at a pop concert in Manchester, as she was able to witness the bravery and resilience of survivors first-hand.
On the 60th anniversary of her first televised Christmas address, Queen Elizabeth said her reflections on the year had made her "grateful for the blessings of home and family", and praised her husband and his "unique" sense of humour.
The 96-year-old prince, also known as the Duke of Edinburgh, has been at the queen's side throughout her 65 years on the throne, and has often grabbed the headlines with his off-colour comments.
Queen Elizabeth, the world's longest reigning monarch, celebrated her platinum wedding anniversary in November. Philip retired from regular royal duties over the summer having carried out more than 22,000 solo engagements.
"I don't know that anyone had invented the term 'platinum' for a 70th wedding anniversary when I was born. You weren't expected to be around that long," she said.
"Even Prince Philip has decided it's time to slow down a little - having, as he economically put it, 'done his bit'. But I know his support and unique sense of humour will remain as strong as ever."
Philip has continued to make occasional appearances, and joined other members of the royal family at a Christmas Day church service on their country estate in Sandringham.
Also joining them for the service was Prince Harry's fiancee Meghan Markle who is spending Christmas with the royals.
The American actress wore a distinctive brown hat as she arrived alongside the Queen's grandson Harry, his elder brother William and his wife Kate.
As they left, both couples briefly chatted to some well-wishers who had gathered to glimpse the royals on Christmas morning.
The Queen, who missed last year's service with a heavy cold, said in her address that she was looking forward to welcoming new members into the royal family next year. As well as Markle, who will marry Harry in May, Kate is expecting a third child.
The royal Christmas broadcast dates back to King George V in 1932 when it was on the radio. It was first televised in 1957.
(Reporting by Hannah McKay in Sandringham, Paul Sandle and Alistair Smout in London; Editing by Andrew Heavens and Robin Pomeroy)
(This story has not been edited by NDTV staff and is auto-generated from a syndicated feed.)