Quick answer
The cookie law is Article 5(3) of the EU ePrivacy Directive and national versions such as UK PECR regulation 6: storing or reading information on a user's device needs informed consent, unless it is needed to transmit a communication or is strictly necessary for a service the user requested.
What is the cookie law?
"Cookie law" is the informal name for Article 5(3) of the EU ePrivacy Directive (2002/58/EC) and the national laws that implement it, such as regulation 6 of the UK's Privacy and Electronic Communications Regulations (PECR). The rule says that storing information on a user's device, or reading information already stored there, is allowed only with the user's consent after clear and comprehensive information, unless the storage or access is needed to transmit a communication or is strictly necessary for a service the user explicitly asked for.
The nickname is misleading in two ways. First, the rule is not about cookies as such: it covers any storage or access on "terminal equipment", which includes localStorage, IndexedDB, tracking pixels that read device data and, in the EDPB's reading, some identifier-based techniques that store nothing. Second, it is a directive, so each EU country wrote its own version, with its own regulator and fines.
The consent requirement in its current form dates from the 2009 amendment (Directive 2009/136/EC), which member states had to transpose by 25 May 2011. Before that, an opt-out was enough. That date is why "the new cookie law" articles from 2011 and 2012 still rank today.
This page is a definition, not legal advice. For how TapCub's settings map onto it, see the last section and do I need a consent banner.
What the rule covers, beyond cookies
The European Data Protection Board settled the technical scope in Guidelines 2/2023 (version 2.0, adopted 7 October 2024). Article 5(3) applies when three elements are present: "information", the "terminal equipment" of a user, and "gaining access" or storing. The guidelines then walk through use cases where all three can be met even without a classic cookie, including tracking pixels and tracking links, data processed locally on the device, tracking based on the IP address the device sends, and unique identifiers.
The UK wrote the same idea into its law directly. Since 5 February 2026, PECR regulation 6(2) also covers "collecting or monitoring information automatically emitted by the terminal equipment", which takes in device signals the browser sends with every request.
The practical rule: if a script places something on the device, reads something from it, or makes the device emit something so you can recognise it later, assume the cookie law applies until a regulator's guidance says otherwise.
The exemptions
The directive has two narrow exemptions, and the UK has added more since 2026:
| Exemption | Where | What qualifies | Typical example |
|---|---|---|---|
| Transmission of a communication | EU and UK | Storage or access solely to carry a communication over a network | Load-balancer session affinity |
| Strictly necessary for a requested service | EU and UK | Needed to deliver what the user asked for | Shopping cart, login session, security token |
| Audience measurement (regulator reading) | France (CNIL) | First-party analytics meeting strict conditions | Basic traffic statistics for one publisher |
| Statistical purposes | UK, PECR Schedule A1 | Sole purpose is statistics to improve the site, clear information, free opt-out, no sharing | Site analytics with an opt-out link |
| Appearance or functionality | UK, PECR Schedule A1 | Adapts the site to the user's preferences, with information and opt-out | Remembering dark mode |
Two conditions are often missed. The CNIL exemption requires, among other things, that trackers are limited to audience measurement for a single publisher, are not cross-checked with other processing, truncate the last byte of the IP address and live no longer than 13 months. And the UK statistical exception does not extend to information automatically emitted by the device (Schedule A1, paragraph 5(2)), so it does not by itself cover fingerprint-style techniques.
Cookie law vs GDPR
The two rules stack rather than compete. The cookie law decides whether you may store or read anything on the device at all. The GDPR decides whether the personal data you then process has a lawful basis, and sets the standard for what "consent" means (freely given, specific, informed, unambiguous; as easy to withdraw as to give).
| Technique | Cookie-law consent needed? | Exempt from consent possible? | GDPR lawful basis still needed? |
|---|---|---|---|
| First-party analytics cookie | Yes by default | France: CNIL conditions; UK: statistical exception with opt-out | Yes, if the ID is personal data |
| localStorage visitor ID | Yes, same as a cookie | Same as above | Yes |
| Tracking pixel reading device data | Yes (EDPB 2/2023) | Rarely; advertising never | Yes |
| Browser fingerprinting | Likely yes (EDPB 2/2023; UK reg 6(2)) | UK statistical exception excludes emitted information | Yes |
| Cookieless hash with daily salt, nothing stored | Debated; depends on what is read from the device | Possible under national readings | Yes, if visitors are identifiable |
| Server log of requests | No storage or access on the device | Not needed | Yes, IPs are personal data |
Read the table left to right: passing the cookie-law column does not finish the job. A server log needs no consent banner, but it still needs a GDPR basis, a retention period and a privacy notice.
UK cookie law after 2026
The Data (Use and Access) Act 2025 replaced PECR regulation 6 on 5 February 2026 and added Schedule A1. Three changes matter for analytics:
- A statistical-purposes exception. First-party statistics collected solely to improve the site no longer need opt-in consent, provided users get clear information and a simple, free way to object, and the data is not shared except to help improve the service.
- Emitted information is explicitly in scope. Regulation 6(2) now covers collecting information the device emits automatically, and the statistical exception does not apply to it.
- Consent can be signalled by settings. Schedule A1 allows consent to be expressed through browser settings or another application.
None of the new exceptions covers advertising or cross-site tracking, so those still need opt-in consent in the UK.
What happens if you get it wrong
Enforcement is national. In the EU, each country's regulator (often the data protection authority) enforces its transposition of Article 5(3), and the GDPR standard of consent applies. The most common findings in published decisions are the same handful of practices:
- Non-essential trackers set before the user makes a choice.
- No reject option on the first layer when there is an "accept all" button.
- Consent inferred from scrolling or continued browsing.
- Pre-ticked boxes, which the Court of Justice ruled out in Planet49 (C-673/17, 1 October 2019).
- "Strictly necessary" used as a label for analytics or advertising cookies.
A quick self-check is to load your site in a clean browser profile, refuse nothing and accept nothing, and list every cookie and storage entry present before you click. Anything that is not strictly necessary is a finding.
How TapCub maps onto the cookie law
Suppose you run a store with visitors in France, the UK and the US, and you want analytics that do not depend on a banner click.
- Know what the script stores. At TapCub's default tier 2, the script writes no cookie and no local storage; visitors are separated by an HMAC of IP address and user agent with a salt, and the address is discarded after use. See how cookieless counting works.
- Check the regional rules. In Configuration › Privacy center, the built-in rule for the EEA and the UK is tier 2 with consent required. Without an analytics-purpose consent signal, those visitors are stored at tier 1: daily salt, no persistent ID, no autocapture, but pageviews and custom events still recorded.
- Pass consent from your banner if you use one. The analytics purpose from your consent management platform goes to the script; before consent, events are queued in memory by default, or dropped if you switch that setting.
- Decide per region with your counsel. Whether a stored-nothing hash is inside the cookie law is exactly the open question in the scope section above. TapCub gives you the switches (tier, consent required, address truncation, retention per region); it does not decide the legal answer.
Sources
- Directive 2002/58/EC (ePrivacy Directive), Article 5(3), EUR-Lex, as amended by Directive 2009/136/EC.
- European Data Protection Board, Guidelines 2/2023 on Technical Scope of Art. 5(3) of ePrivacy Directive, version 2.0, adopted 7 October 2024.
- The Privacy and Electronic Communications (EC Directive) Regulations 2003, regulation 6 and Schedule A1, legislation.gov.uk, in force from 5 February 2026.
- CNIL, Sheet no. 16: Use analytics on your websites and applications.
- Court of Justice of the EU, Planet49 judgment, press release No 125/19, 1 October 2019.
Was this explanation clear?
We use your answers to fix and expand this page.
Couldn’t send. Please try again in a minute.
Thanks for the feedback. We’ll use it to improve this page.You’ve already sent feedback on this page. Thanks.

Data Analyst
Explores traffic sources, conversion funnels, and retention, using clear metric definitions and concrete examples to explain what the numbers mean.