For renters and homeowners alike, finding an affordable place to live in the San Francisco Bay Area is like discovering the needle in an ever-increasing haystack. And there’s no sign of prices falling anytime soon as the strong job market in San Francisco and Silicon Valley lure more people to the area.

How much house can I afford?

Determine how much house you can
afford using our mortgage calculator.

With a 33% increase in home prices across the Bay Area from 2011 to 2013, in many cases, it might make more sense now to rent than to buy. In 2012, buying a home in the Bay Area was 24% cheaper than renting, but by May 2014, that difference had flipped, and it’s 6% more expensive now to buy than rent, according to the New York Times.

And with companies continuing to add employees, every year more people are looking for housing in the area. In 2013 alone, San Francisco added 10,600 people, and San Jose saw 17,000 new residents. If you are new to the region or are looking for a new place to live, you’ve probably wondered: Should I rent or buy, and where?

After analyzing 65 Bay Area cities, NerdWallet discovered it’s not the East Bay, but places in Silicon Valley where renters will find more significant differences in costs between renting and buying. In our top three cities — Palo Alto, Cupertino and Los Gatos, which are all in Santa Clara County — the median home price is typically 28 times the annual rent for a home of the same size, based on the price-to-rent ratios at the real estate website Zillow.

Looking across the Bay Area, 13 of our top 20 cities for renters are in the two counties south of San Francisco — San Mateo and Santa Clara — where price-to-rent ratios are much higher overall than in the East Bay’s Alameda and Solano counties.

To determine what goes into a market that favors renting, we considered three main questions:Is it better to rent than to buy? From Zillow, we gathered price-to-rent ratios from July through September 2014. A higher price-to-rent ratio was weighted positively. A price-to-rent ratio is calculated by dividing the median home price by a year’s worth of rental costs. In other words, a 14 means the median home price is typically 14 times the annual rent for a home of the same size. Of course, buying still might be a worthwhile investment over time depending on your mortgage and if you plan to stay awhile.

For the Bay Area, we made 15 our benchmark based on a calculation by the New York Times, so 15 or over means that it’s better to rent than to buy over the long run. But if you are set on buying, we found nine places — Vallejo, San Pablo, Pittsburg, Suisun City, Richmond, Antioch, East Palo Alto, Oakley and Fairfield — where it’s better to become a homeowner.

Are rental units available? Using the most recent U.S. Census Bureau data (5-year 2013 American Community Survey estimates), we equally weighted the percentage of renter-occupied housing and the median rental vacancy rate. High percentages of renters and vacancy rates were weighted positively. A city favorable for renting must have available units, especially since only 12 of the 65 Bay Area cities had a vacancy rate at or above the state’s rate of 4.9%.

Is rent affordable based on an area’s median household income? From Zillow’s website, we took a year’s worth of median monthly rents averaged from July to September 2014 and divided that by the median household income, which was compiled from census data. This gave us each area’s rent as a percentage of income. A lower percentage scored positively.

In calculating affordability by using median figures, we found that only about a third of cities have rents less than 30% of income, which NerdWallet recommends as a healthy percentage to spend on housing costs.

Here are some other trends we discovered in our analysis:

Price-to-rent ratios make a difference. The places with the highest price-to-rent ratios shot up to the top even though we averaged the three factors equally.

Cities with technology companies ranked well. Each one of the top five cities is home to facilities or headquarters of major technology companies. Perhaps unsurprisingly, median incomes above $100,000 reflect the competitive job markets in those areas. However, certain cities, such as Mountain View, scored lower because of its low supply of rental units.

NerdWallet crunched the data for 65 places with over 20,000 residents in the San Francisco Bay Area’s cities and towns. To see the full data set, click here.

Best Cities to Rent, Not Buy, in the San Francisco Bay Area

1. Palo Alto

Home to Stanford University students and technology professionals, Palo Alto’s housing stock skews toward renters. With 44.6% of housing counted as rentals and the second-highest price-to-rent ratio in the Bay Area at 31.77, it tends to be better to rent than to buy a home here. According to Zillow data, the median home price by fall 2013 had topped $2 million.

2. Cupertino

Cupertino, one of the most affluent cities in Silicon Valley, is the headquarters of Apple, which helps explain the median household income of $129,976. But even with those higher incomes, the price-to-rent ratio of 29.61 indicates that for most people it’s better to rent than to buy a home here. The rental vacancy rate of 4.9% is the highest of the top 20 cities.

3. Los Gatos

In the town of Los Gatos, southwest of San Jose, renters spend about 28.7% of their median household income of $122,476 on rent costs. But it can be more difficult to find a place — vacancy rates and the percentage of housing for renters are lower here than in other cities in our top 10. With one of the highest price-to-rent ratios from our list, renting is 28 times cheaper than buying in Los Gatos. Netflix and Digital Media Academy have based their headquarters in the city.

4. Sunnyvale

In this Silicon Valley city near San Jose, renters pay the lowest median rent of our top 10 at $2,723, and 53% — the highest percentage on our list — of housing is renter occupied, according to census data. Sunnyvale is home to companies such as Yahoo, Lockheed Martin and more.

5. Burlingame

Renters in Burlingame, which is near the San Francisco International Airport, will find a lower median rent here than in other cities in the top 10. Renting is 27.18 times cheaper than buying, based on its price-to-rent ratio. With stops for the Caltrain commuter line, Burlingame is accessible for residents who work in the south bay and valley and also those who commute north to San Francisco.

6. Menlo Park

Home to Facebook and the Stanford Research Institute, Menlo Park has an expensive housing market. Its price-to-rent ratio is 27.18, but census figures show there’s a strong supply of housing for renting, with 43.8% of units renter occupied. Affordability is not one of its virtues, even for those at the median income here, since renters spend roughly 41.3% of their income of $112,262 on housing costs.

7. Campbell

This small San Jose neighbor walks a different path than the other cities in Silicon Valley: It isn’t a base for computer giants, but Campbell is big for people who don’t own a home — 48.2% of housing is occupied by renters.

8. Santa Clara

Santa Clara, San Jose’s neighbor, boasts a large renter population, with 54.9% of housing occupied by renters, in part because of the student population at Santa Clara University and people who work at Applied Materials, Intel and other companies in the city. The median rent of $2,740 is comparable to other cities in the top 10, but its price-to-rent ratio of 21.13 is lower.

9. Fremont

As the closest East Bay city to Silicon Valley, Fremont still has a high median rent of $2,319. Renters spend 27.41% of the median household income of $101,535 on housing costs. Its price-to-rent ratio and percentage of rental housing are lower than in other cities in the top 10, though, making it friendlier for homeowners.

10. Dublin

This city in Alameda County has grown by over 30,000 people in the past few decades, but only 35.6% of housing is renter occupied. Compared to the top nine cities, future homeowners will find Dublin is a better choice with its lower price-to-rent ratio of 20.15. But there’s good news, too, if you plan to rent — the city’s vacancy rate of 5.9% is relatively high for the Bay Area.

Check out this interactive map of our top 10 cities for renters in the San Francisco Bay Area. Click on each icon to see the city’s overall score.

Top 20 Cities to Rent, Not Buy, in the San Francisco Bay Area

City

County

Price-to-rent ratio from July to September 2014

Housing occupied by renters

Rental vacancy rate

Median household income in 2013

Median rent from July to September 2014

Rent as a percentage of median household income

Overall score

1

Palo Alto

Santa Clara

31.77

44.6%

3.7%

$121,465

$3,774

37.28%

76.07

2

Cupertino

Santa Clara

29.61

36.3%

4.9%

$129,976

$3,257

30.07%

75.06

3

Los Gatos

Santa Clara

28.08

35.9%

2.8%

$122,476

$2,930

28.71%

69.52

4

Sunnyvale

Santa Clara

24.97

53.0%

3.9%

$100,043

$2,723

32.67%

69.44

5

Burlingame

San Mateo

27.18

51.7%

2.2%

$84,854

$2,680

37.90%

67.52

6

Menlo Park

San Mateo

26.08

43.8%

3.4%

$112,262

$3,863

41.30%

63.02

7

Campbell

Santa Clara

22.12

48.2%

3.4%

$88,300

$2,373

32.25%

62.10

8

Santa Clara

Santa Clara

21.13

54.9%

4.0%

$91,583

$2,740

35.90%

61.66

9

Fremont

Alameda

22.35

36.8%

3.6%

$101,535

$2,319

27.41%

61.48

10

Dublin

Alameda

20.15

35.9%

5.9%

$115,236

$2,640

27.49%

60.88

11

Foster City

San Mateo

22.24

40.8%

3.5%

$114,260

$2,935

30.82%

60.72

12

Saratoga

Santa Clara

31.02

14.8%

2.0%

$159,212

$5,250

39.57%

60.69

13

Lafayette

Contra Costa

24.86

24.6%

2.1%

$136,207

$2,919

25.72%

60.34

14

Pleasanton

Alameda

22.36

31.2%

3.4%

$118,317

$2,546

25.82%

60.12

15

Belmont

San Mateo

23.09

41.3%

1.8%

$102,895

$2,647

30.87%

59.67

16

Benicia

Solano

19.28

31.3%

6.1%

$88,502

$1,833

24.86%

59.45

17

Los Altos

Santa Clara

32.05

15.3%

0.0%

$157,907

$5,365

40.77%

58.88

18

Alameda

Alameda

20.73

51.9%

3.5%

$74,606

$2,300

36.99%

58.56

19

San Carlos

San Mateo

23.75

29.6%

3.9%

$118,021

$3,465

35.23%

57.97

20

Berkeley

Alameda

21.28

57.9%

3.9%

$63,312

$2,473

46.88%

57.08

Methodology

The score for each place is from the following data:

1. Price-to-rent ratio is 34% of the score. The data are from Zillow, which the real estate website aggregates from its historical listings.
2. Percentage of renter-occupied housing is 16.5% of the score. The figures are from the U.S. Census Bureau’s 2013 ACS, data set DP04.
3. Median rental vacancy rate is 16.5% of the score. The figures are from the U.S. Census Bureau’s 2013 ACS, data set DP04.
4. Rent as a percentage of income is 33% of the score. This percentage is Zillow’s median rent averaged from July to September 2014 and the U.S. Census Bureau’s 2013 median household income. Rental housing includes one- to five-bedroom homes, single-family residencies, condominiums and cooperative housing.

NerdWallet crunched the data for 65 places — cities and towns — in the San Francisco Bay Area. Only places with over 20,000 residents were analyzed. Although census data offer a detailed look at housing across the Bay Area, the figures provide a limited picture of the current rental market.

Top 20 cities for renters in the San Francisco Bay Area (full rankings)

Learning Center

We want to hear from you and encourage a lively discussion among our users. Please help us keep our site clean and safe by following our posting guidelines, and avoid disclosing personal or sensitive information such as bank account or phone numbers. Any comments posted under NerdWallet's official account are not reviewed or endorsed by representatives of financial institutions affiliated with the reviewed products, unless explicitly stated otherwise.

Disclaimer: NerdWallet strives to keep its information accurate and up to date. This information may be different than what you see when you visit a financial institution, service provider or specific product’s site. All financial products, shopping products and services are presented without warranty. When evaluating offers, please review the financial institution’s Terms and Conditions. Pre-qualified offers are not binding. If you find discrepancies with your credit score or information from your credit report, please contact TransUnion® directly.