Over half of prisoners are problem drug users when they arrive at jail
More than £80m is to be spent on new technology and better security to stop drugs being smuggled into English and Welsh prisons, following a review.
Equipment to detect and bar mobile phones, used by dealers, is to be introduced by the Prison Service.
Chairs that scan for goods being smuggled inside bodies are to be introduced in prisons by next March.
The four-month review also found some corrupt prison officers were being paid by prisoners for phones or drugs.
'Betrayal of society'
Justice Secretary Jack Straw warned these prison officers they would be caught and jailed.
He said: "It is a betrayal of society and it is also treacherous to colleagues because with corruption and the smuggling of drugs by prison officers goes major problems of disorder," he said.
"Substantial amounts" of all types of drugs got into prisons, the review by former chief constable David Blakey said.
Methods included visitors smuggling the substances and disguised packages being thrown over prison walls.
The report commissioned by Mr Straw also suggested improving security on prison visits.
Prisoners will wear a one-piece suit with no pockets during visits and there will be more use of "closed visits" where glass separates the prisoner from the visitor.
Mr Blakey said there should be greater examination of prison bank accounts to provide intelligence on drug dealing behind bars.
The report also suggested a review of Rule 39, which prevents letters from lawyers being opened by prison staff.
Mr Blakey suggested that the Law Society, which represents solicitors, should consider a registration scheme in a bid to stop drugs from being smuggled in this way.
The way search dogs are used should be reviewed, the report said.
And it recommended and the creation of a new research and development department to draw up plans for greater use of technology to combat drugs.
The Conservatives said the report did not go far enough to assess or solve the problem.
Shadow justice secretary Nick Herbert said: "What's needed is a fundamental shake-up of the failed testing regime for drugs, concrete proposals for improving security, and decisive action to tackle corruption.
"Only root-and-branch reform to transform the whole culture of our jails will make prisons go clean."
The ratio of inmates testing positive is falling, but anecdotal evidence suggests the problem is getting worse.
Official figures show that drug seizures rose 12% in two years.
The government estimates that 55% of prisoners are considered to be problem drug users when they are admitted.
England's largest jail, Wandsworth, has estimated that about £1m worth of drugs was trafficked within the prison last year.