The Sun newspaper could have been shut down if it had got the facts wrong about the hacking of Milly Dowler's phone in the same way the Guardian did, the tabloid's former editor has claimed.

Appearing before the Leveson inquiry into press ethics, Kelvin MacKenzie said there was a certain amount of "snobbery" in journalism that meant broadsheet newspapers could get away with making mistakes that tabloids would be demonised for.

The Guardian reported in July 2011 that journalists working for the News of the World had deliberately deleted voicemails on the missing schoolgirl's phone, giving her parents false hope she was still alive. The story triggered the furore over phone hacking, which led to the closure of the Sunday tabloid.

But it later emerged that while the journalists did listen to Milly's messages, they were not deleted by reporters, but removed automatically by her phone provider.

MacKenzie told the inquiry on Monday that had The Sun made that error it "would have come very, very close to being shut down".

"The Guardian sticks it [a correction] away on page 10 and hopes they can get away with it," he said. "The Guardian got that story completely wrong and nobody has taken it up."

MacKenzie edited The Sun between 1981 and 1994 and is famed for his provocative headlines including "Gotcha", which topped the paper following the sinking of the Argentinian ship General Belgrano during the Falklands war.

He told the inquiry that the paper had become increasingly cautious in recent years and that even he had become "less bullish" towards the end of his tenure.

MacKenzie recounted the time the paper had to pay £1m in damages to Elton John after publishing story that claimed the singer had hired rent boys. He told the inquiry how a furious Rupert Murdoch had called him seconds after learning of the settlement to give him "non-stop abuse" for 40-minutes over the damage done to the paper's reputation.

But despite acknowledging Murdoch's heavy involvement in the running of The Sun at the time, he denied that the media mogul had ever ordered the tabloid to "go after" anyone he did not like.

At a previous session, broadcaster Anne Diamond had claimed she had been targeted by the paper after confronting Murdoch over it's behaviour. MacKenzie dismissed the allegation and said Diamond was a "devalued witness".

He also told the inquiry that there were double standards when it came to judging whether the hacking of a phone was justified.

He said that a tabloid would be treated differently than a broadsheet if it had published a story, based on hacking, showing a prime minister had circumvented his cabinet in order to take the country to war.

"If you publish it in The Sun you get six months in jail, if you publish it in the Guardian you get a Pulitzer prize," he said.

MacKenzie has previously described the inquiry into press standards set up in the wake of the phone hacking scandal as"ludicrous" and suggested it was only being held to cover up for David Cameron's "obsessive arse-kissing" of Rupert Murdoch.

He told a Leveson Inquiry seminar in October that his approach to fact checking stories was "if it sounded right it was probably right and therefore we should lob it in".

Asked to clarify those remarks today, he said that the word "lob" meant to put a story in the paper "in a slow arc" after first having thought about it rather than simply "chucking" it in.

Lord Justice Leveson insisted that his inquiry into press standards will continue whatever the outcome of inquiries into how Milly Dowler's voicemails came to be deleted. He said he had received a submission from the Guardian about how it came to publish its original story.

He is also due to receive the results of the review carried out by Metropolitan Police into how the messages were deleted.

"I can make it clear, however, that whatever the outcome of this new evidence I have no intention of suggesting either to the Home Secretary or to the Secretary of State for Culture, Media and Sport that as a result this inquiry is no longer justified," he said.

Proceedings at the inquiry were briefly interrupted by a heckler who shouted "ask him about Michael Stone". View the video below.