By WCCO-TV Staff

MINNEAPOLIS (WCCO) — Minnesota is among the best states in which to raise a family, according to a new study.

WalletHub scored all 50 states in five categories: family fun, health and safety, education and child care, affordability and socioeconomics. Each category was evaluated using multiple factors, and states were given a total score out of 100.

Minnesota ranked fourth, with a total score of 58.79. The state ranked in the top 10 in health and safety, affordability and socioeconomics.

According to WalletHub, no state has a higher median family salary. Minnesota also earned praise for its low percentage of families in poverty and low separation and divorce rate.

The study found Massachusetts is the best state for families, while Mississippi ranked 50th.