The Mail on Sunday continued using a private detective for 18 months after he was raided in an investigation into the illegal trade of personal information, the Leveson Inquiry heard today.
The Information Commissioner's Office uncovered a "treasure trove" of evidence linking newspapers to the sale of private data when it searched the Hampshire home of Steve Whittamore in March 2003, the inquiry has been told.
Peter Wright, editor of the Mail on Sunday, said his journalists continued using Whittamore until September 2004.
The paper's managing editor issued an instruction to staff in February 2004 that "inquiry agents" should not be commissioned to obtain information like addresses without clearance from heads of department, the inquiry heard.
Mr Wright said: "From that point onwards, Whittamore was rarely used. We stopped using him altogether in September 2004, apart from two payments which nobody can quite explain.
"But effectively he was used only on very rare occasions from February 2004, and virtually stopped altogether in September 2004."
Robert Jay QC, counsel to the inquiry, suggested that the Mail on Sunday was "running a risk" by continuing to use Whittamore after his arrest.
Mr Wright replied: "I know that our action dated from the point at which we became aware that he was going to be prosecuted.
"It was around the turn of the year 2003/04, and in February that year we took steps to stop the use of Whittamore, or at least only use him when we were extremely sure that what he was doing was legitimate and there was a good reason to do it."
Whittamore was convicted of illegally accessing data and received a conditional discharge at London's Blackfriars Crown Court in April 2005, but no journalists were prosecuted, the inquiry has heard.
Mr Wright confirmed that the Mail on Sunday paid about £20,000 to Whittamore over a number of years for information that "might be illegal".
But he said he did not know at the time that his paper had commissioned the private detective to supply criminal records.
He told the inquiry that Mail on Sunday reporters on the road used Whittamore's services to obtain addresses at a time when it was time-consuming to get them through other means.
Mr Wright said his staff believed that the investigator used legitimate sources and so he was "alarmed" when it was suggested that this was not the case.
The editor added: "There was something of a learning process at this period.
"We were coming to terms with very rapidly changing technology, and reporters and other writers in our newsroom were finding ways of adapting to technology more rapidly than editors were aware that they were doing so.
"And, rightly or wrongly, it took us a time to catch up with what had taken place."
Mr Wright, who has edited the Mail on Sunday since 1998, also revealed that the maximum the paper has paid for a major interview or book serialisation deal over the past year is about £50,000.
He said that, to the best of his knowledge, his paper had never paid a police officer for information.
But he confirmed that it had on occasion paid other public officials, most commonly members of the Armed Forces who wanted to bring to the public's attention things that they had experienced in war zones.
Mr Wright said the three stories which produced a noticeable boost in the Mail on Sunday's circulation in the past 12 months were the royal wedding in April, the tsunami in Japan in March and the tragic M5 motorway crash in November.
He added: "Exclusive stories... would be part of the mix of things which readers would buy the paper for, but it wouldn't move individual sales for us."
The editor said he met senior Government ministers and shadow ministers at the party conferences but otherwise had never had dinner with a politician.
"My policy is to have a perfectly cordial relationship with politicians but to try and keep the newspaper completely independent of all parties, and certainly not to get into bed with individual politicians," he said.
Mr Wright called for a new press regulator with a "standards and compliance" arm that could summon editors to give evidence about issues at their papers and impose sanctions if they refused to co-operate or gave false testimony.