Canada is one of the happiest countries in the world, according to a global ranking of well-being that uses measures such as life expectancy and corruption to assess the progress of nations.

Canada ranks sixth in the United Nations' second world happiness report. That's down a notch from the last ranking – not because Canadians are any less happy, but because Switzerland leapfrogged into the top five. Denmark tops the list, followed by Norway.

It finds well-being is growing in much of the world, particularly in sub-Saharan Africa and Latin America – in contrast to oft-dreary news of civic unrest and economic malaise. As a whole, people have become a bit happier and more generous in the past five years.

Story continues below advertisement

"Life is getting better in unsung ways in many places – enough so that the world is slowly becoming a happier place," said John Helliwell, professor emeritus of economics at the University of British Columbia, who co-edited the 150-page paper with Jeffrey Sachs of Columbia University and Richard Layard of the London School of Economics. More governments, such as those in the U.K., South Korea and Bhutan, are considering broader measures of life satisfaction as a guide for decision making, beyond focusing on GDP.

The study looked at both peoples' current mood and their overall life satisfaction. It found six factors help shape changes in well-being: per capita GDP, life expectancy, having someone to count on, freedom to make life choices, generosity and freedom from corruption.

The report urges policy makers to make happiness a key target of development. Its research finds happy people "live longer, are more productive, earn more, and are also better citizens."

The biggest surprise, Mr. Helliwell said, is that so many countries showed improvements in their citizens' happiness in the five-year study period.

Of 130 countries for which there is data, happiness improved in 60 countries and worsened in 41 in a Gallop world poll. Life satisfaction grew the most in countries such as Angola, Albania and Ecuador between the 2005-07 and the 2010-12 studies. It ebbed in Egypt, Greece and Myanmar.

By region, people are feeling better in Latin America and worse in many industrialized nations. Happiness has ebbed in the United States, and tumbled in Greece, Spain, Italy and Portugal amid income and job losses. Canada is an exception, where measures of happiness stayed high in the five-year period.

"A range of factors lead people to think that life is getting better," from improved governance to education levels, said Prof. Helliwell, who has traveled to the United Arab Emirates, Brazil and the U.K. to advise governments in policies that promote well-being.

Story continues below advertisement

Mental illness is the single greatness determinant of unhappiness, causing disability, absenteeism, misery and lost economic potential, researchers found. Yet even in advanced economies, only a third of people who need it are in treatment. They urged governments to make treatment for anxiety disorders, depression and psychosis more readily available.

The report is published by the UN Sustainable Development Solutions Network, with analysis of the Gallop world poll conducted by the Canadian Institute for Advanced Research.