The UK has climbed three places to seventh in the global prosperity index and had one of the best business environments in the world.

Norway retained top spot in the Legatum Institute index, which takes into account a number of factors including the economy, business environment, education, health and national environment.

The UK was named the fourth best nation for business environment – behind the US, New Zealand and Canada, and second best for natural environment – losing out to Slovenia.

But it fell four places when it came to safety and security after a number of terrorist attacks in 2017 and 2018.

The Legatum Institute said the UK's rise to seventh was down to improvements when it came to social capital and the natural environment.

It said: “This year Britons have reported a greater level of social capital with increased civic participation, and more people reporting willingness to help others. Moderate gains in natural environment were also made.”

The report also highlighted a mixed year for Germany, which fell from 11th to 14th.

The legalisation of same sex marriage towards the end of 2017 led to a higher score when it came to personal freedom but it fell away in health due to the increased prevalence of diabetes and obesity.

Portugal made one of the biggest improvements, with its largest gain coming in its economy following a growth acceleration – reported rises in tolerance towards immigration also helped.

The US improved on its standards of living score for the fifth consecutive year and jumped one place in the overall ranking to 17th.

Director of policy at the Legatum Institute Stephen Brien said: “A nation is prosperous when it has an open economy, an inclusive society with strong institutions and empowered people who are healthy, educated and safe.”