Many people dream of living in New York or Los Angeles—rubbing shoulders with celebrities and Instagramming food from the hottest restaurants. They dream of flashy jobs and fat paychecks.

That is, until they scroll through Craigslist or Zillow and determine they could never afford a fourth-floor walk-up above a noisy bar, let alone afford to buy a house in such an expensive city.

If "they" is really "you," you might want to consider a midsize city where your paycheck will go the furthest.

10 Cities with Excellent Cost-of-Living Ratios

For this list, we turned to a recent report by Glassdoor, which looked at salaries and housing costs for the 50 most populated metro areas across the US.

With that data, Glassdoor determined each city's cost-of-living ratio—the median annual base salary divided by the median home value.

The results show that where you live and how much you make are directly related.

"Though there are certainly other financial factors to consider when taking into account total cost of living, this data reinforces that pay typically goes further in [midsize] cities versus big metropolitan areas, where there is often tighter competition for housing," said Dr. Andrew Chamberlain, Glassdoor's chief economist.

It probably won't surprise you that New York City, Boston, and San Francisco fared poorly, with ratios of 18%, 17%, and 11%, respectively. Some of the winners might surprise you, though. Here are the 10 cities where your paycheck will go the furthest.

10. Louisville, Kentucky

Cost-of-Living Ratio: 39%

Median Base Salary: $54,000

$54,000 Median Home Value: $137,500

When most people think of Louisville, they think of big hats and baseball bats. But this city has a lot more going for it—not least of all is its southern charm.

UPS employs more than 20,000 people here, and the city has become a major center for the health care and medical sciences industries—both of which are growing fields with good pay.

9. Kansas City, Missouri

Cost-of-Living Ratio: 39%

39% Median Base Salary: $58,000

$58,000 Median Home Value: $147,500

Kansas City has the most expensive homes on the list and the second-highest salaries. You'll find friendly people and a lot of love for the local baseball team here.

Jobs are available in health care, education, and government, and companies such as Garmin, Hallmark, and Sprint have headquarters in the larger Kansas City metro area.

8. Birmingham, Alabama

Cost-of-Living Ratio: 40%

40% Median Base Salary: $50,800

$50,800 Median Home Value: $128,000

If you love barbecue, you'll love Alabama. And Birmingham offers excellent restaurants, easy access to the outdoors, and passionate college football fans.

Its biggest industries are banking and insurance, health care, and logistics and transportation. Major employers include the University of Alabama at Birmingham, Regions Financial Corporation, Honda, and Mercedes-Benz.

7. Cincinnati, Ohio

Cost-of-Living Ratio: 40%

40% Median Base Salary: $57,179

$57,179 Median Home Value: $143,400

Even though I'm a Michigan grad and therefore not supposed to like Ohio, I have a soft spot for Cincy. My favorite activity is wandering the scenic riverfront park and then having a picnic while I watch the boats sail past.

Procter & Gamble, the University of Cincinnati, and Kroger are major employers here.

6. St. Louis, Missouri

Cost-of-Living Ratio: 40%

Median Base Salary: $56,896

$56,896 Median Home Value: $141,900

How aren't more people flocking to St. Louis? This city's got it going on.

Thanks to its large student population, it has a bumping nightlife and lots of nice cafes. Another highlight is the City Museum, which is basically a jungle gym for adults and kids.

Big industries include biotech and health care, and Boeing employs more than 15,000 people in the area.

5. Indianapolis, Indiana

Cost-of-Living Ratio: 43%

Median Base Salary: $56,000

$56,000 Median Home Value: $130,200

My friend's dad—a well-traveled person—calls Indianapolis his favorite city. Although I'll never fully understand that, I can see why it's appealing.

I lived in this affordable city during middle school, and it offers midwestern values, a healthy population of young people, quality sports teams, and a convenient location in the heart of the country.

Its major industries include health care, education, finance, and tourism.

4. Cleveland, Ohio

Cost-of-Living Ratio: 44%

Median Base Salary: $55,000

$55,000 Median Home Value: $125,500

Downtown Cleveland is cool—and not just because it's home to the Rock & Roll Hall of Fame. There's a fun and active culture about the city, as evidenced by the many restaurants on the walkable East 4th Street.

Cleveland's major industries are advanced manufacturing and health care.

3. Pittsburgh, Pennsylvania

Cost-of-Living Ratio: 45%

Median Base Salary: $56,896

$56,896 Median Home Value: $126,700

With American Eagle, GNC, and Dick's Sporting Goods headquartered in the area, in addition to several manufacturing and steel companies, incomes are good in Pittsburgh.

Story continues