When it comes to the pursuit of happiness, the Phoenix area might be doing alright.

Via ktar.com

According to a report by WalletHub, Valley cities like Scottsdale, Chandler and Gilbert are among the happiest places to live in the U.S.

The study bases its findings off of metrics that fall into three primary categories: emotional and physical well-being, income and unemployment, and community and environment. Those are calculated by more specific metrics, like depression rates, suicide rates, sleep adequacy, income growth and others.

Scottsdale finished 13th in the ranking of 150 cities. Among metrics that made up its overall score was its second-place finish in “highest sports participation rate.” Per capita, just one city in the U.S. has more sports participants than Scottsdale (Seattle, Wash.).

Gilbert, Ariz. finished in 16th place overall. It ranked No. 2 in the U.S. for lowest divorce/separation rate, behind Fremont, Calif.

Other Phoenix-area rankings include: Chandler, 28th; Peoria, 30th; Tempe, 38th, Mesa, 53rd; Glendale, 77th; Tucson, 84th, and; Phoenix, 85th.

Detroit, Mich. finished last place at No. 150. The “happiest” city, according to WalletHub, is Fremont, Calif.

Earlier this year, WalletHub also ranked Scottsdale the best city in the nation to get a job, as well as the best place for an active lifestyle.