Renting is now only slightly cheaper than owning a home, according to a new study.

Median rent was $1,319 per month nationwide, while the median mortgage was $1,600 per month at the end of 2019. Compared to the previous year, rent rose 4%, while mortgage payments declined 1%, according to a new study by that analyzed housing costs in 593 U.S. counties with populations over 100,000.

“Lower mortgage rates really benefit the buy side of the equation. The fact that rates are down is really helping narrow the gap between buying and renting,” said Danielle Hale, chief economist at

Monthly payments are cheaper for renters in 84% of the counties analyzed. In these counties, home prices were 260% higher than the national median price, while rents were only 79% more.

But the gap in renter-friendly counties is narrowing even faster than it is in the rest of the country. With rents in Brooklyn, New York City, and Santa Cruz, Calif. decreasing 24%, 20% and 18%, respectively — compared to the 2.8% decrease nationally.

“In these areas, the markets are so large and well established that, for the most part, buying comes with a huge premium. These tend to be markets that attract not only homeowners and investors but international investors, too — like New York and California,” said Hale about these counties, including Santa Barbara, Calif., Monterey, Calif., San Mateo, Calif., and San Francisco, Calif.

Monthly mortgage payments were actually cheaper for buyers compared to renters in 16% of the counties analyzed, up from 12% of counties the year prior. In those counties, like Clayton, Ga. and Baltimore City, Md., homes were 53% cheaper than the national median of $300,000. Rents in those areas were only down 11% from a year ago.

“In these areas, there are a lot of homes available for homeownership and not a lot of rental inventory. The country is facing limited building and a lack of housing availability, but these areas don’t tend to have those issues,” said Hale, referring to those counties, which include Cumberland, N.J., Richmond, Ga., and Vigo, Ind. More than 25 counties, including Cleveland, Bronx County, N.Y., Indianapolis, and Columbia, S.C., joined the list of buyer-friendly locations in 2019.

Sarah Paynter is a reporter at Yahoo Finance. Follow her on Twitter @sarahapaynter