Nine new prisons are to be built this year, housing 10,000 inmates and allowing the closure of a group of inner-city prisons, the government has announced.

The plan, which will run into billions of pounds, was announced by George Osborne and Michael Gove and is projected in the long term to save up to £80m a year.

The chancellor and justice secretary said the vacated land would be used for housing. They said opening the new sites and closing the old jails would make it easier to run a prison reform programme.

In a speech at a building site in London, Osborne also announced that four government departments have agreed deep spending cuts of 8% a year for the next four years.

The Treasury and the Departments for Transport, Environment and Communities & Local Government are the first ministries to agree cuts in a spending review intent on slashing £20bn from the cost of government.

Osborne argues that controlling £4tn of government spending over the next five years is essential to guarantee national and economic security.

The prisons announcement does not mean the Ministry of Justice has reached a wider agreement on its spending plans, however, including the future of legal aid.

The nine new jails are in addition to one already being built in Wrexham and expansions under way at HMP Stocken in Rutland and HMP Rye Hill in Warwickshire. The first prison to be sold will be HMP Reading, which was built in 1844, according to the Treasury announcement.

The Treasury did not say which other prisons would close but there has been speculation that the Ministry of Justice would like to shut Pentonville and Brixton in London. Gove has previously referred to Pentonville as the “most conspicuous example of failure within the prisons estate”.

Osborne said details would be announced as part of the spending review at the end of November.

He said the review was about reform as much as it was about making savings. He said: “One important step will be to modernise the prison estate as many of our jails are relics from Victorian times on prime real estate in our inner cities. So we are going to reform the infrastructure in city centres and sell the estates to build much needed homes.”

The two men made the announcement before visiting Brixton prison in south London.

Gove said: “We are about to design out the dark corners which too often facilitate drug taking and violence. We will be able to build a prison estate which allows prisoners to be rehabilitated so they turn away from crime.”

In his short period as justice secretary, Gove has raised hopes among the prison reform lobby that he would be willing to reduce prison numbers and use more community punishments, but this will require taking on arguments in the tabloids that insist prison works and crimes deserve a punitive response.

Gove has already told the Howard League for Penal Reform that he hoped prison numbers would fall over time. He also said the use of body cameras would improve prison staff’s behaviour and reduce the danger of assault by inmates.

Under the influence of Gove, David Cameron told his party conference that he wanted to end the “sterile lock ‘em up or let ‘em out debate”.

Gove has also spoken of giving prison governors greater control over their prisons.