Image caption The rules would require UK companies to keep a wider range of data about users

The government's draft Communications Data Bill details plans to increase the amount of data gathered about the web and mobile habits of anyone in the UK.

But why is the bill needed and what will be retained?

What are the proposals?

The government wants to make internet service providers (ISPs) and mobile operators log much more data about what their customers are doing. If the bill is passed, information about who people call, text, tweet and IM, what games they play, when they post on social networks and who they send web mails to will be logged. Data would be kept for 12 months.

How is that different to now?

Currently communications firms only retain data about who people send emails to, and who they ring. The new law would cover a much wider class of data.

What is the argument for change?

The government says advances in technology and changing patterns of use mean its existing regulations, known as the Regulation of Investigatory Powers Act, are inadequate. Data saved on computers or mobiles is key to many tens of thousands of police investigations every year, it says, and it needs improved powers to get at this information quicker.

In addition, many of the communications services people use are based outside the UK. With few powers to compel these service providers to hand over data, the government says it needs powers to gather information in the UK.

Image caption The way the net handles data makes it inevitable that police will invade privacy, say critics

What is the opposing view?

Opponents say the proposals radically expand the data being gathered from just data that businesses need in the course of their business to a comprehensive and intrusive log of online life. Such a database is ripe for abuse, they warn. It could also be targeted by hackers keen to get at such a lucrative store of personal data.

In addition, say critics, government plans are flawed because the way the many technologies treat data means police will inevitably intrude on privacy. For instance, in the past it was easy to separate who was being called from what was being said. With data this distinction breaks down and means any investigation will see lots more than just basic contact data.

Critics also say the bill will push many more websites to use secure browsing standards which will make it harder for police to investigate.

What is possible in technical terms?

It is technically possible, though very expensive, to log everything a person does on the web, their mobile and on their home PC, laptop or tablet. The fewer precautions a person takes to hide what they are doing or scramble the contents of messages the easier it is to grab information. The government says data retention system envisaged in the bill will cost about £1.8bn to build. Critics say it will cost much more.

Are there limits to what is possible technologically?

Encryption, which scrambles data, can make it hard to look at the content of messages. However, the way the net and most other modern communication technologies work make it very hard for anyone to hide who they are calling or mailing and the websites they are visiting. The hard part for investigators is identifying the means through which someone is communicating. Although technologies exist to obscure browsing habits, few use them.