By New York City standards, it was a modest real estate transaction: not quite four-tenths of an acre for $500,000.

The price was only half of what the cash-poor seller had hoped for. The space-squeezed buyer got what it desperately needed: more room.

For dead bodies.

The buyer, Green-Wood Cemetery in Brooklyn, is worried about running out of space for graves. The seller, Old First Reformed Church in Park Slope, Brooklyn, does not need the plots that its parishioners never filled in what amounted to a cemetery-within-a-cemetery, a circle of land deep inside Green-Wood that the church had owned since 1860.

Since then, Green-Wood has buried more than 570,000 people in the grounds surrounding the Dell, as Old First’s plot is known — among them the newspaper publisher Horace Greeley, the political boss William M. Tweed and the artist Jean-Michel Basquiat. But Green-Wood, whose 478 acres make it close to 60 percent of the size of Central Park, feels pressed for room as it and other older cemeteries that have been burying bodies for decades confront a finite reality.