All perfect praise be to Allaah, The Lord of the Worlds. I testify that there is none worthy of worship except Allaah, and that Muhammad, sallallaahu ‘alayhi wa sallam, is His slave and messenger.
It is permissible to sell a plot of land which is the site of graves, and it is permissible to sell it at any price. What is forbidden in Islam is to sell a plot of land that is especially endowed (given as Waqf, or a charitable trust) for the purpose of turning it into a graveyard because it is not permissible to dispose of Waqf endowments through purchase, sale and so on.
The evidence of the permissibility of selling a plot of land that contains graves is that Anas ibn Maalik said: “When the Prophet, sallallaahu ‘alayhi wa sallam, arrived at Al-Madeenah he dismounted in the upper part of Al-Madeenah in the company of a tribe called Banu `Amr ibn `Awf. He stayed there for fourteen nights. Then he sent for Banu An-Najjaar and they came armed with their swords. It is as if I am watching on (just now) as the Prophet was sitting on his mount with Abu Bakr riding behind him and all Banu An-Najjaar around him till he dismounted at the courtyard of Abu Ayyoob’s house. The Prophet liked to pray wherever the time for the prayer was due, even at sheep-folds. Later on he ordered that a mosque be built and sent for some people of Banu-An-Najjaar and said, “O Banu An-Najjaar! Offer a price for this (walled) piece of land of yours.” They replied, “No. By Allaah! We do not demand payment for it except from Allaah.” Anas added: There were graves of disbelievers in it…” [Al-Bukhari and Muslim]
Allaah Knows best.