Jurors should face up to two years in prison if they search the internet for information about cases beyond the facts revealed in court, the Law Commission has recommended.

Judges should also be given powers to remove jurors' mobile phones, and all internet-enabled devices must be confiscated during jury room deliberations, according to the commission's proposals for reforming contempt of court regulations.

The report suggests that the attorney general ought to take on responsibility for ordering the media to remove previously published stories from websites if they are deemed to jeopardise a fair trial.

The Law Commission argues that potential jail sentences for jurors have become necessary because of the wide availability of information online. Professor David Ormerod QC, the commissioner leading the review, explained that he was trying to balance defendants' right to a fair trial, the interests of jurors and public confidence in the legal system.

Many of the powers already exist within contempt of court procedures. But Ormerod said: "Putting this prohibition on a statutory setting would bring greater clarity and certainty for both courts and juries. Members of the jury would know the rules, the wrongdoing could be prosecuted in the same way as other crimes and jurors accused of contempt would benefit from the normal protections of the criminal process."

There have been a series of recent incidents in which jurors have researched online and then told other jurors about their findings.

In July, a juror who gave others at Kingston crown court details about a fraud trial that had not been revealed in court was sentenced to two months in jail. The case collapsed and a new trial had to be held.

Internet-enabled devices should not be automatically taken away from jurors when they enter a court building, the Law Commission proposes, but they should be removed during the period when the jury is deliberating at the end of a trial.

Judges should nonetheless have the power to order confiscation at any time, for example when jurors visit the scene of a crime.

The Law Commission believes its proposals on removing stories from websites will not require media organisations to monitor every trial in the country to ensure that archived stories, still available online, pose a risk to a fair trial.

By requiring the attorney general to make a formal approach to the media when it is feared there is a significant risk that previously published material could undermine justice, the commission intends that interventions will be rare.

Responding to the recommendations, the attorney general, Dominic Grieve, said: "Juror contempt is a serious risk to justice but people are often not aware of the consequences.

"The Law Commission's proposal to make it an offence for jurors to search for information about their case on the internet or by other means would make the position absolutely clear and would, I hope, reduce the need for future prosecutions.

"[The law Commission has] attempted to strike a very careful balance between freedom of expression and the right to a fair trial. I will now need to discuss the recommendations carefully with my government colleagues before we respond formally."

Responding to the Law Commission recommendations, the justice minister Damian Green said: "Technology and the wealth of information available to us all at the touch of a button has changed the way we live. It's right that we look at the impact this has on our laws and make any changes where necessary. We welcome the Law Commission report on this important, and highly relevant, issue. We will respond formally in due course."