On this page
- What are strictly necessary cookies?
- How does the cookie consent exemption work?
- How to tell if a cookie is strictly necessary
- Strictly necessary cookies examples
- Which cookies are not strictly necessary?
- Necessary vs functional cookies
- How to check your strictly necessary cookies
- Frequently asked questions
What are strictly necessary cookies?
Strictly necessary cookies are cookies a website needs to provide a service the visitor has explicitly asked for. If the visitor logs in, the site needs a cookie to remember that they are logged in. If they add a product to the cart, the site needs a cookie to remember the cart.
The key words are "strictly" and "asked for". It is not enough for a cookie to be useful to you, or for your business model to depend on it. The question is whether the feature the visitor is using right now stops working without it.
What are essential cookies?
"Essential cookies" is another name for strictly necessary cookies. Many banners and cookie policies use it as the category label, and the same rule applies: an essential cookie may do nothing beyond running the service the visitor requested.
Are mandatory cookies the same thing?
Yes. "Mandatory cookies" and "required cookies" are labels for the same group. They are often shown as a switch that is locked on in the banner settings. The label does not make a cookie exempt. A tracking cookie labelled "mandatory" is still a tracking cookie, and it still needs consent.
How does the cookie consent exemption work?
In the EU, the cookie consent rule comes from Article 5(3) of the ePrivacy Directive. Storing or reading information on a visitor's device needs consent, with two exceptions:
- storage used only to carry a communication over a network, and
- storage strictly necessary to provide a service the user explicitly requested.
Most sites rely on the second one. The UK's PECR has the same two exceptions and, since 5 February 2026, further exceptions added by the Data (Use and Access) Act 2025, including one for statistical purposes. The exemption covers consent only. It does not let you hide the cookie. You still have to tell visitors what it is and what it does, which in practice means listing it in your cookie policy.
EU regulators explained how to read the exemption in the Article 29 Working Party's Opinion 04/2012 on Cookie Consent Exemption. The examples below follow that opinion.
No consent needed does not mean nothing to disclose. A strictly necessary cookie needs no click in the banner, but it still goes in your cookie policy with its purpose and lifetime.
How to tell if a cookie is strictly necessary
Ask these four questions about each cookie. It counts as strictly necessary only if it passes all four.
- Did the visitor ask for this feature? Logging in, paying or filling in a form: yes. Being measured or shown ads: no.
- Does the feature break without the cookie? The feature has to stop working, not just work slightly worse.
- Is the cookie used only for that feature? A login cookie that also feeds an ad profile loses its exemption.
- Does it last only as long as the feature needs? A cart cookie that lives for years is hard to justify.
What the cookie does matters more than who sets it. A payment provider's fraud check cookie can pass, while your own first-party analytics cookie does not.
Strictly necessary cookies examples
These usually pass the test, as long as they are used only for the purpose shown.
| Cookie purpose | Why it counts |
|---|---|
| Login session | Keeps a signed-in visitor signed in from page to page. Without it, every click would log them out. |
| Shopping cart | Remembers what the visitor added. Without it, checkout is impossible. |
| Form progress | Keeps what the visitor typed across the steps of a multi-step form. |
| Load balancing | Sends a visitor's requests to the same server so the session keeps working. |
| Security and bot protection | Detects repeated failed logins, stops abuse of a form the visitor is using, or protects against request forgery. |
| Consent choice | Remembers the visitor's cookie choice so the site can respect it and the banner does not come back on every page. |
The consent cookie shows the logic well. The visitor asked for their choice to be respected, and the site cannot respect it without remembering it. That is why CookieRule stores each visitor's choice in a cookie named cb_consent.
Which cookies are not strictly necessary?
These are the common mistakes: cookies that site owners file under Necessary because the site "needs" them, even though the visitor never asked for what they do.
Are analytics cookies strictly necessary?
No. Analytics helps you run the site, but the visitor did not ask to be counted, and every page works without it. Some national regulators allow tightly limited audience measurement without consent, but that is a separate rule with its own conditions, not the strictly necessary exemption. In the UK, the Data (Use and Access) Act 2025 added a separate statistical purposes exception to PECR from 5 February 2026, which allows analytics cookies without consent if visitors get clear information and a simple, free way to object. That is also a separate rule, not the strictly necessary exemption. File analytics under Statistics.
Are chat widget cookies necessary?
Usually not. A chat widget that sets cookies on every page load, before anyone opens it, is setting them for a service nobody has asked for yet. Once a visitor starts a conversation, a cookie that keeps that conversation going is much easier to justify. Load the widget only after consent, or only when the visitor opens the chat.
Are video embed cookies necessary?
Not when the video provider uses them for tracking or advertising, which many embedded players do. The visitor asked to watch a video, not to be profiled. A short session cookie that the player needs only to play the video can pass. Check what the provider actually sets.
Are ad frequency capping cookies necessary?
No. Limiting how often a visitor sees the same ad sounds visitor-friendly, but the visitor never asked for ads in the first place. Frequency caps, conversion pixels and retargeting cookies all belong in Marketing.
| Cookie | Strictly necessary? | Category to use instead |
|---|---|---|
| Analytics and measurement | No | Statistics |
| Chat widget loaded on every page | No | Preferences |
| Video embed tracking | No | Marketing |
| Ad frequency cap | No | Marketing |
| Remembered language or theme | Usually not | Preferences |
Necessary vs functional cookies: where is the line?
Functional cookies, often called preference cookies, make the site more pleasant to use. They remember a language, a region, a dark theme or the video volume. The site still works without them. It just forgets those settings.
That is where the line sits. If visitors would still get the service they asked for, with a little more clicking, the cookie is functional and belongs in Preferences. If the service fails without it, the cookie is necessary.
There is one grey area. A language the visitor chose themselves can count as part of the service they asked for, and regulators have accepted short-lived cookies of that kind. A language picked for them and remembered for a year is a preference. When you are unsure, file the cookie under Preferences. Asking for consent you did not strictly need is safe. Skipping consent you did need is not.
How to check your strictly necessary cookies with CookieRule
You cannot judge cookies you do not know about, so start with a list of what your site actually sets.
- Run a scan. CookieRule opens your site in a real browser, follows links to other pages and lists every cookie, every local and session storage key, and the tracker requests it finds. Each scan visits your site twice: once as a new visitor and once after Allow All. Cookies that appear only after consent are found too. See how cookie scanning works.
- Review what landed in Necessary. When CookieRule's cookie database recognises a cookie, it gets a category marked Our classification, along with its vendor, purpose and retention. Run every cookie under Necessary through the test above.
- Change any category you disagree with. Use the pencil button on the Cookies page. Your choice always wins over the suggested one, and Use our classification switches back. Unknown cookies set by your own site show as Yours to classify, because only you know what they do.
- Tag the scripts that set everything else. A category on its own does not block anything. Blocking happens per script, so give each non-essential script a consent category.
Tagging a script means changing one attribute and adding another. The browser does not run a script with type="text/plain". Once the visitor allows the script's category, the snippet replaces it with a working copy:
<script type="text/plain" data-consent="statistics" src="https://analytics.example.com/tracker.js"></script>Strictly necessary scripts can stay untagged and run as usual. CookieRule also holds back known vendors, such as Google Analytics, the Meta Pixel and YouTube embeds, but you should still tag your own scripts. The details are in how to block scripts until consent.
Keep your cookie policy in sync. The cookie declaration lists your cookies by category, starting with Necessary. It updates after each scan and whenever you change a category, so the list that strictly necessary cookies still need stays up to date.

Find out which of your cookies really are necessary
Scan your site in a real browser, review every cookie filed under Necessary, and hold back the scripts that set the rest until visitors agree.
Frequently asked questions
They are cookies a website needs to provide a service the visitor explicitly asked for, such as staying logged in, keeping a shopping cart, finishing a form or protecting a login from abuse. If the feature still works without the cookie, it is not strictly necessary, however useful it is to the site owner.
No. The ePrivacy Directive and the UK's PECR exempt them from consent, so they can be set before the visitor makes a choice in the banner. The exemption applies only while the cookie is used for the requested service and nothing else. You still have to tell visitors about these cookies.
No. Analytics helps you understand and improve your site, but visitors do not ask to be measured, and every page works without it. Some regulators allow narrowly limited measurement without consent under separate national rules, but analytics cookies do not fall under the strictly necessary exemption. File them under Statistics.
Necessary cookies are needed for a requested feature to work at all. Functional, or preference, cookies make the site more convenient, for example by remembering a language or theme, and the site still works without them. Necessary cookies need no consent, but functional cookies generally do. When in doubt, treat a cookie as functional.
Yes. The exemption removes the need for consent, not the duty to inform visitors. Your cookie policy should list each necessary cookie with its provider, purpose and lifetime, just like every other cookie. A cookie declaration that updates after every scan keeps that list accurate as your site changes.