David Cameron is preparing to set out his views tomorrow on the Leveson Inquiry, which could recommend new laws governing the press.

If the Prime Minister decides to back state regulation, Mr Nelson said The Spectator would not attend meetings, pay fines or "heed its menaces".

"If the state uses its powers to compel publications to join the government scheme, each of us faces a choice: do we sign up, or defy the law? In tomorrow’s Spectator, we make our choice," Mr Nelson wrote on the magazine's website.

"To do so would betray everything that The Spectator has stood for since 1828."

Mr Nelson also said he was willing to take the consquences of disobeying the law, as the magazine's editor.

"It’s unclear what penalities would be imposed on those publications that refuse, on principle. As editor, I’d probably find out," he said.

The publication, once edited by Boris Johnson, the London Mayor, says it would "happily" sign up to any form of self-regulation proposed by the industry but would not obey any laws.

"I would say that we thought long and hard about this, but it wasn’t a tough decision," Mr Nelson wrote today.

"For anyone who works at The Spectator, it’s a no-brainer. In the basement of 22 Old Queen St lie our archives, showing how we have been implacably opposed to the principle of state regulation of the press — not because it protects the press, but because it protects the public."

Mr Nelson said the magazine has a long history of standing up to politicians who want to restrict freedom of speech.

It accused Nick Clegg, the Deputy Prime Minister, of saying he "admires the press while conspiring to undermine it with legislation".

"In 1829, we lambasted The Sunday Times for putting press freedom at risk with sloppy libels," he wrote. "In 1833 we took aim at Lord Brougham, then Lord Chancellor, for doing what Nick Clegg is doing now: saying how much he admires the free press, while conspiring to undermine it with legislation.

"The canard of ‘statutory regulation’ was raised in parliament in 1952. ‘Everyone who really understands what freedom of the press means and cares about it,” we argued, “must resist such a proposal to the utmost’."

Mr Nelson also argued that state regulation of the press would lead to state regulation of the internet - just like China.

He added that he believes the Prime Minister is a "pragmatist" and "friend of liberty", who knows that state regulation will "crush" press freedom.

The Spectator's declaration comes after more than 80 politicians wrote an open letter saying state regulation poses the greatest threat to press freedom for 300 years. The list of names includes nine former Cabinet ministers.

Several current cabinet ministers, including Michael Gove, the Education Secretary, and Eric Pickles, the Communities Secretary, have openly warned against newspaper laws.

However, the Cabinet is divided with Maria Miller, the Media Secretary, and Nick Clegg, the Deputy Prime Minister, understood to be pushing for tough laws. More than 40 backbench Conservatives have also come out in favour of state regulation.