Deciding whether to buy or rent depends on several factors. Among them: where you live, how long you plan to stay in your home and how home prices compare to rents in the area.
Zillow crunched the numbers to figure out how long a new homebuyer would have to own their home before it would make better financial sense to buy. It's at this "breakeven horizon" that total rental costs would exceed the total cost of home ownership.
In three-quarters of the U.S., that horizon is three years or less, according to Zillow's chief economist, Stan Humphries.
Of course, in some markets, like New York and San Francisco, home prices are so high that it takes much longer than that -- five years or more. In those cases, it makes more sense to rent.
And the breakeven point can vary wildly within metro areas. In the Boston metro area, for example, it can range from just over two years in the town of Lawrence to a decade in suburbs like Concord and Brookline.
To make these calculations, Zillow accounted for the costs associated with buying a home, including the down payment and transaction costs (such as commissions and fees), mortgage payments, property taxes, maintenance costs and tax deductions, among other things. It then compared that with rental costs, including monthly payments and commissions and adjusted the numbers for inflation and forecasted home value and rental price increases.
Here's how the nation's 10 biggest cities fared. See the whole story on CNNMoney.
Rent or Buy? 10 Major Metros
Buy or Rent? 10 Major Cities
Median home price: $368,000 Median rent: $2,600 Breakeven time: 5.1 years
Ever dream of owning your own Brooklyn brownstone or Manhattan pied-a-terre? Keep dreaming.
New York is one of the most expensive markets to buy a home in with a median home price of around $450,000. (The most expensive home on the market in New York costs $100 million.) Even with the highest rents in the nation, it still takes more than a decade of ownership before buying a place in one of the city's five boroughs makes more financial sense than renting.
Outside the city limits, prices get a little more reasonable. The breakeven time for the entire metro area is just over five years.
The best places to buy, however, are far removed from Manhattan in the distant suburbs of New Jersey. In Lake Como, N.J., for example, the breakeven time is just 1.8 years.
Median home price: $393,800 Median rent: $1,800 Breakeven time: 4.3 years
Even though home prices in Tinsel Town plunged by close to 40 percent after the housing bubble burst, homebuyers still pay a premium to live in the Southern California sunshine.
The median home price in Los Angeles is more than twice the national median. As a result, it takes a long time for buyers to breakeven with renters. If they aren't planning on staying four years or more, they're better off renting, according to Zillow.
Although rents aren't that cheap, either. The growing population has put pressure on housing supplies in the L.A. metro area, helping to push rents about 30 percent higher than the national average.
Median home price: $209,300 Median rent: $1,430 Breakeven time: 2.8 years
Chicago's housing market appears to be slowly turning the corner. Home prices in the Windy City rose for the fourth consecutive month in June, according to S&P/Case-Shiller.
However, while median home prices are nearly the same as the nation as a whole, rents are considerably higher. That makes buying a much better choice financially -- even for those who are planning to move out in as few as three years.
And, in some of the least expensive communities, such as the town of Dixmoor, south of Chicago, breakeven times for buyers are just one year. While in the tonier northern suburbs, such as Kenilworth, it's better for the long haul. Breakeven time there is more than 13 years, according to Zillow.
Median home price: $163,100 Median rent: $1,030 Breakeven time: 2.1 years
Texas' largest metro area is blessed with plenty of open land to build on and a local government policy that's friendly to development, which has helped keep housing here extremely affordable.
The median home price in the Dallas metro area is 20 percent below that of the nation and, as a result, it takes only a couple years of ownership for buyers to break even on their investments, according to Zillow. Meanwhile, demand from a steady flow of new residents has pushed rents slightly higher than the average city.
The wealthy suburb of Westover Hills, west of Fort Worth, boasts some of the most expensive home prices compared with rental costs. The breakeven time there is nearly 11 years. But in nearly every other community in the metro area, the breakeven time is less than three years.
Median home price: $187,300 Median rent: $1,300 Breakeven time: 3 years
Urban blight in some central city neighborhoods has kept a tight lid on home prices in Philadelphia and the surrounding towns.
That has helped to keep breakeven time for homebuyers within city limits to just 2.3 years, a little less than the metro area as a whole.
Buyers who venture out to the stronger housing markets in Philadelphia's wealthy suburbs will have to wait a little longer for their purchase to pay off.
In the fancy towns along the Main Line west of the city, such as Tredyffrin, it takes more than eight years to break even, while in the bucolic far suburbs in New Jersey, like Haddonfield, it takes 11 years to break even, according to Zillow.
Median home price: $379,100
Median rent : $1,850
Breakeven time: 3.5 years
Uncle Sam's ongoing hiring spree has helped the D.C. housing market recover more quickly than most other metro areas.
Home prices have gained more than 11 percent since hitting bottom in early 2009, according to S&P/Case-Shiller. The median home price in the area is now more than twice the national median, while median rents are a steep $2,000-plus a month.
Most of the best housing buys are inside the Beltway in Maryland's suburbs. In the town of Landover, for example, it only takes 1.4 years for a home purchase to start making more financial sense than renting, according to Zillow.
In the expensive suburbs west of the Beltway, it can take much longer for the math to work out for homebuyers. In towns such as Upperville, Va., and Middleburg, Va., it can take seven to nine years to break even.
Median home price: $162,800 Median rent: $1,594 Breakeven time: 1.6 years
Few markets got hit as hard as Miami did in the housing bust. Home prices are still off by nearly 50 percent from their 2006 highs.
In many communities, owning a home for a year is all it takes for an investment to pay off, according to Zillow. Even in some of the most expensive towns like Fisher Island and Key Biscayne, the breakeven point is only about six years.
Buyers may want to strike while the iron is hot, however. Prices have been on the upswing lately, rising about 7 percent between last November and June -- about twice the gain for the average city.
Median home price: $176,200 Median rent: $1,950 Breakeven time: 5.9 years
Foreclosures have plagued the Atlanta area recently. The metro area saw steady increases in foreclosure activity in the first half of this year.
Part of the increase is due to the national mortgage settlement which set new rules that banks should use to pursue foreclosures. The settlement, which was reached as a result of the robo-signing scandal, has opened the way for banks to clear their backlogs of foreclosures more quickly.
Now the market is flooded with short sales and bank-owned properties, depressing prices -- and creating bargains. The median home price in Atlanta has fallen to well below $180,000, which, combined with low mortgage rates, has made buying a great deal in most area communities.
But, as in most cities, it all depends on where you buy. In a depressed town like Jonesboro, where incomes is about 50 percent lower than the state average, you could breakeven in just over a year. But if you opt to purchase in the pricier Druid Hills area, it could take closer to 7 1/2 years.
Median home price: $363,700
Median rent : $1,950
Breakeven time: 4.3 years
Boston real estate is wicked expensive no matter if you are renting or buying. Land is pricey and space is priced at a premium.
In fact, home prices here are 80% above the national median. And rents average nearly $2,000 a month in the metro area. That's high, but renting is still the better option for anyone planning a stay of less than five years.
Still want a place of your own? If you want it to pay off, you'll have to be patient -- or willing to commute. The best buying bargains are in old mill towns outside of the city, in towns like Lowell and Lawrence, where it takes just over two years for buyers to break even. But if you want to be closer to the city, in Brookline, for example, you'll have to wait more than 10 years to break even, according to Zillow.
Median home price: $363,700 Median rent: $1,951 Breakeven time: 5.9 years
Limited land and an influx of well-paid tech workers has helped to make San Francisco one of the most expensive cities to live in the nation.
While rents are steep -- only trailing New York's -- home prices are triple the national level. As a result, the Bay area is most definitely a rental market.
It takes nearly six years for homebuyers to realize any sort of financial advantage over renting in the San Francisco metro area, according to Zillow. And in more desirable neighborhoods, like Sausalito or Mill Valley, it takes almost nine.
Farther outside of the city, in fancier communities like Atherton, Piedmont and Burlingame, it can take 20 years or more.