Auckland Council has spent $12 million on a property bordering the botanic gardens in Manurewa to stop it being developed for housing.
Mayor Wayne Brown said buying the 1.6ha leafy estate would allow the council to extend the botanic gardens.
The block of land on Hill Road has a house and pool - and is zoned for two storey housing intensification.
The purchase comes after the council cut some services, axed 500 jobs and sold some of its Auckland Airport shares to plug a $375m budget hole.
Brown said the purchase was justified because it would benefit future generations and provide more open space.
"We have made a decision that will protect one of the region's most treasured assets and provide both guaranteed access and greater protection to the Gardens," he said.
"We had to act now to protect it from inappropriate development, or this opportunity would have been lost forever."
The council paid $12.37m for the property, with $10.76m of that funded by debt.
"We don't have funds sitting in reserve for open space purposes, so the choice to debt-fund this acquisition is based on spreading the cost of a strategic capital investment across the generations that will use it," said Brown.
Funding to develop the property for the botanic gardens would be considered in the later years of the long-term plan for 2024 to 2034. Partnerships or external funding could be used to turn the land into part of the gardens.
The property will be held as a regional park and will be protected in perpetuity as public land for natural, cultural, ecological, botanical and recreation uses.
Manurewa-Papakura ward councillor Daniel Newman said he "wholeheartedly" supported buying the land.
"The land is zoned for Mixed Housing Suburban and full development of the site would have been a probable consequence of a private sale," Newman said.
Council Planning, Environment and Parks Committee chairperson Richard Hills said buying the land opened a future opportunity to develop themed gardens.
"It's exciting to think that this space could offer the opportunity to include Māori and Pasifika traditional gardens that provide educational, ecological and cultural experiences for visitors and future generations," Hills said.
The land could also be used to help resolve traffic management problems in the area surrounding the gardens, he said.
The council's representative on the Friends of Auckland Botanic Gardens executive, councillor Christine Fletcher, said she was pleased not to lose the land bordering the gardens to a housing development.
"The Gardens carries all the hallmarks and values of the regional parks network, whose founders were referred to as 'dreamers of the day' for their foresight in securing such valuable land as open space for generations of Aucklanders to enjoy.
"It is heart-warming to think that we have been able to add to that legacy," Fletcher said.