It began with fears that venues were sinking into the mud following weeks of rain, serious concerns over whether there would be enough security guards to keep the public safe and the biggest call on the army outside wartime.

The reaction to the Olympic torch as it toured the nation had raised the hopes of organisers, but the last-ditch security crisis dented optimism as the volume of public disquiet about the £9.3bn cost to the public purse grew louder.

Just over a fortnight later, London's Games ended bathed in sunshine as the country giddily rose to acclaim a host of new sporting heroes amid hopes that it would lead to a new sense of ourselves and — in the words of a Locog slogan that once seemed cloying but now feels appropriate — "inspire a generation".

Even the hamfisted marketing slogans of Team GB — "One Team, 60m Strong" — seemed to take on a new hue once bathed in the golden light of the achievements of Mo Farah, Chris Hoy, Ben Ainslie, Jessica Ennis, Kath Grainger, Victoria Pendleton and the rest.

The London 2012 organising committee chairman, Lord Coe, said he was humbled but not surprised by the reaction of the British public and the mood catalysed by the athletes and the 70,000 volunteers that became his most potent cheerleaders.

"I don't think any city that stages the Games is ever the same afterwards. No country is ever the same," said Coe. "It has been important to showcase all that we hold dear in this country, in the way that all Games do."It was a job that began with Danny Boyle's opening ceremony, which packed the history and hopes of the British nation into three hours that received rave reviews at home and abroad, and proclaimed: "This is for everyone!" As it turned out, it was.

As the focus moves on to whether London's Olympics can provide the sporting, economic, social and regeneration legacy it promised, the International Olympic Committee president, Jacques Rogge, said it was also important to remember the "intangible" effect of the Games on the people. He summed up the shift in the national mood by saying that the Games had achieved the impossible by inspiring Londoners to talk to one another on the tube network.

Atmosphere

It became so well worn that by the end of the Games it had almost become a cliche, but every athlete from at home and abroad who competed was quick to pay tribute to the atmosphere within the venues.

Some purists felt organisers overdid the loud music and flash presentation, but many more felt it immersed the crowds effectively in sports that might be new to them.

From the hush of the archery at Lord's to the jollity of the beach volleyball and the tumult of the boxing arena at ExCeL, excited, knowledgeable crowds packed out every venue. For the big moments in the stadium, at the velodrome or on the rowing lake, the atmosphere rivalled any sporting event ever held on the planet.

On the park, a Truman Show style mood of collective goodwill held for the entire period. Beyond the venues, for 17 days London felt a more pleasant place to be.

Part of that may have been down to the fact organisers had successfully terrified Londoners to the point where they stayed off public transport but it was also because there was a collective sense of goodwill in the air. Buoyed by inspirational athletes from every part of the country, it spread far beyond the capital.

Although organisers denied it, if there was one minor gripe it was that the live sites with big screens were not as busy as they might have been. But that's largely because everyone was at home watching the Olympics on television — the BBC posted huge audience figures and enjoyed its own boost to its reputation.

Volunteers

Determined to pluck the best from previous Games, Lord Coe had always waxed lyrical about the effect the volunteers at the 2000 Games in Sydney had on the national mood and was determined they could do a similar job here. The London organising committee's human resources director, the redoubtable Jean Tomlin, is one of many unsung heroes of these Games. She devised the scheme that enlisted 70,000 volunteers from 250,000 original applications.

But the enthusiasm, wit, knowledge and good humour they brought to long days performing often menial tasks in their garish purple uniforms was all their own. Often lodging with relatives or paying for their own accommodation, their firm belief that they were part of something bigger transmitted itself to visitors from home and abroad and to the rest of the city. Coe said they represented "the best of British" — the challenge will be how to harness their enthusiasm and raise the profile of the armies of volunteers who already do similar work week in, week out across the country.

Organisation

Brazil's sports minister said that one of the lessons that they would take from London's organisers was the value of pre-planning. Bequeathed a clutch of glittering venues finished ahead of time and under budget by the Olympic Delivery Authority, Locog nevertheless had to undertake the challenge of delivering 26 simultaneous world championship in one of the busiest and most congested cities in the world. By any measure, they delivered.

Paul Deighton, the Locog chief executive, will have to answer for his part in the eve-of-Games security shambles but he deserves praise for microscopic attention to detail in planning and obsessive focus on delivery. That mattered most of all in the crucial few weeks before the Games when huge temporary arenas had to be built in cramped and congested areas of the city.

If there was one fly in the ointment it was a ticketing policy that sometimes appeared to be made up on the hoof. The original ballot was hugely oversubscribed, and probably the fairest way of distributing tickets, but there were issues with the Ticketmaster system all the way through to the last day of the Games.

And lessons will have to be learned about the consequences of the unwieldy manner in which the IOC handles ticket sales, along with the overgenerous allocation of seats in accredited areas that led to the public anger over empty places, particularly in the opening days.

Sport

It's the sport, stupid, could have been the mantra of the organising committee. Deighton explained his job as removing anything that could get between the British public and the action, so convinced was he that once the world's best athletes were presented to a sports-mad nation success was virtually assured. As Rogge has said, success for the home nation is also a prerequisite for a Games to really take flight.

For Team GB, it took until Helen Glover and Heather Stanning took gold in the women's coxless pairs on the fifth day of the Games to achieve liftoff. Bradley Wiggins followed soon after, and the British team were on their way to their best medal haul for more than a century on the back of unprecedented focus and investment in high-performance sport.

The highlights flowed thick and fast. Old heroes were venerated anew -Sir Chris Hoy's sixth gold and Ben Ainslie's fourth in consecutive Games — and new ones were created in sports that normally barely feature on the media radar, from shooting to taekwondo and dressage to women's boxing. The success of female athletes was a familiar theme, with long overdue victory for Kath Grainger with Anna Watkins and Nicola Adams becoming the first women's boxing gold medallist ever deserving of particular mention.

There was widespread appreciation for the dedication and humility that all of Britain's competitors brought to their task. Mo Farah's double victory, following a magical hour a week earlier that will remain one of the most venerated in British sporting history, set the seal on an extraordinary performance.

But it wasn't just British athletes who stepped up to the plate. The Muhammad Ali of the track, Usain Bolt, confirmed his legendary status and the American swimmer Michael Phelps laid claim to the title of greatest ever Olympian. Other standouts included David Rudisha's 800m world record and the ongoing duel between the US and Jamaican sprint teams.

Security

Security at the Olympics has faded as an issue over the past fortnight, which will have delighted the police, MI5 and armed forces — and come as a huge relief to G4S. But the company's problems are far from over. The security firm generated all the wrong kind of headlines on the eve of the event, embarrassing ministers and forcing emergency statements in the House of Commons.

The inquest at Westminster will begin next month, and MPs will be unforgiving.

In all other respects, the security of the Games has been a success.

Whitehall officials privately acknowledge that G4S's problems with recruitment and training were, in some ways, quite useful. They distracted attention from the potential terrorist threat, and gave the police and the armed forces a chance to restate their reputations as trusted public servants, a cut above the profit-motivated managers from the private sector.

Fears about the over-militarisation of the games were also over-played. The sight of thousands of soldiers in khaki did not prove unsettling to the crowds at the Olympic venues. Quite the opposite.

All the anecdotal evidence suggests their presence came as a welcome relief. And the troops seemed to enjoy the experience too, even though many had had to cancel holidays.

The Ministry of Defence likes nothing better than riding to the rescue at short-notice, while retaining a Uriah Heep-ish humbleness about doing so. In the shadows, MI5 has been paddling hard to stay ahead of potential problems, process intelligence and reassure agitated intelligence officials from other countries.

A triumphant games for MI5 will be one in which it doesn't get written about at all. The service will not start to relax until after the Paralympics but so far, so good.

Economy

The prime minister and his government have tried to talk up the economic legacy of the Games. But the short-term impact of the Olympics on the economy can be summed up in three words: modest, temporary and localised. When combined with a bounceback in activity from the extra bank holiday to celebrate the Queen's Jubilee, the extra spending associated with the London Games will be enough to ensure that the UK will not suffer a fourth successive quarter of decline in the three months to September.

But the boost, as the Bank of England's chief economist, Spencer Dale, noted last week, is unlikely to be that big. Ticket sales and the sale of TV rights for the Olympics will be included in the third-quarter GDP figures, and should add 0.1 percentage points to growth.

On top of that there will be the receipts from tourism and the additional spending from UK consumers. The early signs were not promising, with reports of empty hotels, deserted shops and tables to be had at London's poshest restaurants.

As the Games have progressed, the picture has started to look brighter. John Lewis reported a 22% year on year increase in sales at their department stores, and detected a consumer feelgood factor across the country. Data for high street footfall showed a pick up in the number of shoppers and London hotel occupancy rates were up on a year ago.

The John Lewis figures, however, display a marked north-south divide, with year on year sales up by a quarter in Poole and Croydon but by 5%

in Glasgow and Newcastle. Ben May, UK analyst at Capital Economics, said he expected a 0.3% boost to real household spending from the Games in the third quarter (including ticket sales), but said this would be partly offset by lower spending later this year. "Previous boosts to consumer confidence from one-off events have been fleeting," May said.

Transport

It's hard to credit already that Coe once thought transport "the achilles heel" of London's bid for the Games. Or that anyone would worry about jamming thousands of spectators into the creaking tube system, or have concerns over the capital's winding streets accommodating Zil lanes for Olympic VIPs.

Not only did London ensure all athletes – and spectators – made it to the venues in time, even the predicted queues and crush failed to materialise. So successful was the "big scare", as some uncharitably dubbed Transport for London's information campaign, that those who did not either abandon or alter their commute reported the quietest journeys in memory.

Yet while angry retailers spoke of ghost town London, TfL pointed to record overall numbers on the network, growing to a peak of 4.5m tube journeys on the Tuesday of the final week.

The figures vindicate the strategy of Peter Hendy, the TfL commissioner responsible for most Olympic transport, who walked the line between bridling at suggestions that the capital would not cope and pushing the message that only the craziest commuter would plan to ride the Jubilee line as normal during the Games. Charts waved under the noses of employers since 2011 suggested gridlock at key stations if working patterns didn't change. Rush-hour commuters stayed away: as TfL puts it, they heeded the message and that kept London moving. Now Hendy hopes they will still listen for the Paralympics, after the holidays when underlying traffic will be higher.

There was some good fortune. In the final days before the Games there were serious failures of key tube lines, and even the flagship Javelin service. But once the crowds arrived, only hiccups occurred.

Luck, perhaps, but built like most Olympic success on long, extensive, thorough preparation. That included creating a new integrated control centre, getting staff and unions on side, extending capacity, issuing Travelcards to spectators to avoid ticket queues, drafting in volunteers and issuing constant information. Altogether, a transport system so easy the prime minister could use it.