The UK Information Commissioner’s Office (ICO) has published a guidance advising website owners about the new cookie law, asking them to refrain using cookies without explicit user consent.

From 26 May, when the new regulation will be in effect, website owners will have to get users to ‘opt in’ before downloading cookies onto their computers. They cannot rely on browser settings anymore, said ICO.

Browsers and sites use cookies, which are text files stored in the computers of users, to help users navigate frequently visited sites faster by storing information including usernames and passwords. But Web companies often use cookies to track user preferences for behavioural advertising. At present, enabling cookies is a feature often used in general for browsers which is part of Internet settings.

The new rules will apply to mobile phones as well.

The ICO told companies, "The law which applies to how you use cookies and similar technologies for storing information on a user’s equipment such as their computer or mobile device is changing on 26 May 2011."

"You will need a user’s consent if you want to store a cookie on their device."

The UK adoption of Euro tracking rules that will come into force on 26 May.

The companies are exempt from such rules only under exceptional conditions where the user has asked them to do so, such as in online sales, said ICO, but websites must provide users with "clear and comprehensive information" about the purposes of storage.

The ICO also admitted that it will be difficult to implement the law.

It said, "The ICO recognises that cookies perform a number of legitimate functions. We also recognise that gaining consent will, in many cases, be a challenge."

Information commissioner Christopher Graham said, "The implementation of this new legislation is challenging and involves significant technological considerations. That’s why we’ve already consulted a wide range of stakeholders.

"But we want to spread the net as wide as we can and would welcome further comments from others who have practical examples to share. This advice is very much a work in progress and doesn’t yet provide all of the answers."

The ICO has not finalised how errant companies will be punished.

It said, "The government’s view is that there should be a phased approach to the implementation of these changes…The key point is that you cannot ignore these rules."

The ICO will also publish advice for the general public about the new law.

The EU has set a deadline of 25 May for the implementation of its new web-tracking rules. The e-Privacy Directive was passed in Brussels in 2009.