Millennials are flocking to US cities where they may never be able to afford a home

"2 Broke Girls" on CBS.
CBS Photo Archive | Getty Images

Young people in the U.S. are flocking to cities where eye-popping real-estate prices mean they may never be able to afford to buy a home.

More than 12,000 millennials moved to San Francisco's Castro ZIP code, for example, where the median home costs more than $1.9 million. Nearly 2,500 moved to New York's Battery Park City, where median home values are also quite high. Meanwhile, 67 percent of younger millennials and 61 percent of older millennials have less than $1,000 in savings, and a growing share have nothing saved at all.

Using data from Zillow, CNBC Make It identified median home values for the top 10 places RENTCafé determined that millennials moved between 2011 and 2016.

While housing prices are close to the median in a couple of these places, they're above the national median in eight of the 10 ZIP codes. And in three of the 10 ZIP codes — located in notoriously pricey states like and  — typical homes can cost well over $1 million. 

Here are the top 10 places with the largest increase in millennials over that five year period, and the median home values there:

Los Angeles, California

Neighborhood: Downtown, 90014
Percent of millennial increase: 91.4
Number of new millennials: 3,000
Median home value: $533,500

Los Angeles, California

Neighborhood: Downtown, 90013
Percent of millennial increase: 60
Number of new millennials: 4,700
Median home value: $567,200

New York, New York

Neighborhood: Battery Park City, 10282
Percent of millennial increase: 54.5
Number of new millennials: 2,300
Median home value: No Zillow data. Real-estate website Redfin lists the average home sale price over the last month at $825,000.

Location alone won't determine if your home is a great investment, but this will

Portland, Oregon

Neighborhood: Kerns / Laurelhurst, 97232
Percent of millennial increase: 51.8
Number of new millennials: 5,700
Median home value: $600,700

New York, New York

Neighborhood: Lincoln Square, 10069
Percent of millennial increase: 47.7
Number of new millennials: 2,200
Median home value: $1.9 million

Jacksonville, Florida

Neighborhood: Riverside, 32204
Percent of millennial increase: 45.3
Number of new millennials: 3,000
Median home value: $194,600

Los Angeles, California

Neighborhood: Mid-Wilshire, 90048
Percent of millennial increase: 38.9
Number of new millennials: 10,300
Median home value: $1.7 million

Here's how far $300,000 will get you in these states

Philadelphia, Pennsylvania

Neighborhood: Kensington, 19125
Percent of millennial increase: 37.4
Number of new millennials: 11,200
Median home value: $265,000

San Francisco, California

Neighborhood: Castro, 94114
Percent of millennial increase: 37.4
Number of new millennials: 12,500
Median home value: $1.9 million

Washington, D.C.

Neighborhood: Southwest Waterfront, 20024
Percent of millennial increase: 37.2
Number of new millennials: 5,100
Median home value: $403,300

To generate its national rankings, RENTCafé looked at ZIP codes with total populations of over 600,000 residents. To generate its rankings by state, researchers analyzed ZIP codes in the 250 largest U.S. cities. ZIP codes with less than 1,000 millennial residents were eliminated, as were ZIP codes that overlapped with University Campuses and U.S. Military Bases or those that contained penitentiaries and correctional facilities.

Kevin O'Leary: Use this test to decide if you should rent or buy a house

About half of those born between 1980 and 1995 still rent, according to one recent study, because expenses like , in conjunction with high down payments, . The extravagant cost of renting, especially in trendy cities, makes it even harder to save.

Data from Apartment List in 2017 showed that, although 80 percent of millennials would like to purchase real estate, very few are in a good position to buy, largely because they have nothing put away.

Given their current savings rate, millennials are 10 years or more away from home ownership, especially in more popular cities, Apartment List concludes. Young residents of pricey San Jose, California, will have to be exceptionally patient: Odds are they won't be in a good position to buy an apartment there for "almost 24 years."

Since housing prices and the cost of living can , it's good to plan ahead. If you're looking to buy a home, be sure you're ready to  and consider some of the markets where homes are most affordable for millennial buyers. Southern and Midwestern towns tend to be good bets.

And if you're going to continue to rent, check out these , and .

Like this story? Subscribe to CNBC Make It on YouTube!

Don't miss: This is the No. 1 source of financial stress in DC—and it's not taxes or the high cost of housing

Video by Mary Stevens and Andrea Kramar

Millennials are making a big mistake by not owning their homes, says one financial expert