Dirty, unfriendly and expensive: London still voted the best city in the world

London may have put on a cheerful face during the Olympics but tourists have still rated the city poorly in terms of friendliness, cleanliness and value for money, a survey has shown.

Of 40 cities worldwide, London this year ranked second to last for the friendliness of its locals, according to a poll by travel website TripAdvisor.

Only Moscow fared worse, while Mexico's Cancun ranked first.

Britain's capital barely performed better in the nine other categories of the poll, ranking 28th for safety, 26th for cleanliness and 35th for best value for money.

On the upside, London was rated fourth best city for shopping - behind New York City, Bangkok and Dubai - and fifth for the quality of taxi services.

The study was based on responses from 75,000 TripAdvisor users surveyed last month.

"While London hasn't ranked particularly highly by those that have reviewed the city this year, it's important to remember that many of the respondents may have experienced London before major changes were made or post the events of the summer," said Emma Shaw, a spokeswoman for TripAdvisor.

London was still voted the best city in the world in TripAdvisor's 2012 Travellers Choice Awards, Shaw noted.

"This study perhaps proves that even a great city isn't going to be perfect in every way," she said.