A stretch of one of Sydney's last undeveloped headlands has been spared from sell-off less than two months after revelations the site was being sized up for thousands of apartments.

But Federal Environment Minister Greg Hunt's announcement that a 50-hectare section of the Malabar Headland will be made into a state national park has been dismissed as "cheap politics" by Labor, which claims it tried to make the same handover three years ago.

The currently undeveloped Malabar headland had been in developers' sights. Credit:Peter Rae

Mr Hunt said he hoped the land would be transferred to the state government by June 30, adding that the federal government was "steadfast" in ruling out the sale of any part of the 160-hectare site, just 12km from central Sydney.

"The whole of the headland will be kept in public hands for perpetuity," Mr Hunt said.