Ann Arbor is a great city.

That's part of the reason so many people willingly pay upwards of $50,000 in annual tuition and fees to attend the University of Michigan as out-of-state students.

According to its December 2015 survey, Wallethub.com, a personal finance website, ranked Ann Arbor as the best college town in America.

The site said the city was named the top college town for the quality education U-M provides, its low crime rate, and the relatively affordability of things like gym memberships and traditional student fare like pizza and burgers.

The study ranked Ann Arbor near the middle of the pack for "wallet friendliness," while it ranked high in terms of opportunities and its "youth-oriented environment." It also has the fifth-highest number of students per capita out of all the towns polled.

Wallethub reviewed 326 cities, each with a population of at least 7,500 students, using 23 different academic, social, and financial metrics, including the the cost of living.

College Station, Texas, home of Texas A&M University, ranked second on the list, while Iowa City, Iowa -- home of the University of Iowa -- ranked third, Provo, Utah -- home of Brigham Young University -- was fourth, and Gainesville, Florida -- University of Florida -- was fifth.

In October, SmartAsset, a financial technology company that uses different metrics to rank college towns, ranked Ann Arbor as the seventh-best college town.

SmartAsset uses unemployment rate, rate of violent crime, rate of property crime, average discretionary income and number of restaurants, bars and entertainment venues to create its lists.

Jeremy Allen is the higher education reporter for The Ann Arbor News. Follow him on twitter at @JeremyAllenA2. Contact him at 810-247-4625 or jallen42@mlive.com.