---
title: "Ask before you track opens · Agent Wranglers"
url: https://agentwranglers.se/playbook/email/email-privacy/open-tracking-consent
id: EML-74
level: Required
applies: email, eu-users
region: EU
risk: law
updated: 2026-10-27
build: a2a6bdfed830
tokens: 1004
licence: "CC BY 4.0"
licence_url: https://creativecommons.org/licenses/by/4.0/
---

# Ask before you track opens

For AI agents: the [site map](https://agentwranglers.se/llms.txt) lists everything here, and this page sits under [Email privacy](https://agentwranglers.se/playbook/email/email-privacy.md).

By [Agent Wranglers](https://agentwranglers.se/authors/agent-wranglers.md). Updated 2026-10-27.

- ID: EML-74
- Level: Required
- Chapter: [Email privacy](https://agentwranglers.se/playbook/email/email-privacy.md)
- Rule: Load an open-tracking pixel or a per-person tracking link in marketing mail to people in the EU only after they agreed to that tracking. Send everyone else untracked mail.
- Check: Render a newsletter for a test contact in the EU without tracking consent. It holds no remote image on your tracking host and no per-person link token. Give the consent and render again, and the pixel appears.
- Risk: A law broken
- Applies when: The project sends email, or has users in the EU.
- Region: European Union (EU). The duty comes from the law there. The rule applies only when the project serves people there, and its Applies when also holds.
- How: The EDPB's guidelines on the ePrivacy Directive, Article 5(3), name tracking pixels and tracked links in email as access to the reader's device. That needs consent unless it is strictly needed for the service the person asked for. France's CNIL published a recommendation on pixels in email on 14 April 2026. It needs consent for open rates, profiling and fraud scoring. It exempts receipts, account and security mail, and a narrow measure of whether mail still arrives. Ask for tracking consent in the sign-up form, apart from the consent to get the mail. Store it next to the marketing consent, as [Have consent before any marketing message](https://agentwranglers.se/playbook/notifications/channels-and-preferences/marketing-consent.md) says. Render each message with or without the pixel per recipient.

## Examples

**Using these examples:** they show one way to follow this rule. Keep the behaviour and the check, not the syntax. Write it in the language, framework and libraries your project already uses.

### JavaScript example

```js
function trackingPixel(contact, messageId) {
  if (!contact.consents.has('email-tracking')) return '';
  return `<img src="https://links.example.com/o/${messageId}" width="1" height="1" alt="">`;
}
```

### Python example

```python
def tracking_pixel(contact, message_id: str) -> str:
    if "email-tracking" not in contact.consents:
        return ""
    return f'<img src="https://links.example.com/o/{message_id}" width="1" height="1" alt="">'
```

## Sources

- [EDPB Guidelines 2/2023 on the technical scope of Art. 5(3) of the ePrivacy Directive](https://www.edpb.europa.eu/system/files/2024-10/edpb_guidelines_202302_technical_scope_art_53_eprivacydirective_v2_en_0.pdf)
- [CNIL, Recommendation on tracking pixels in email](https://www.cnil.fr/fr/recommandation-pixel-suivi-courriels)
- [ePrivacy Directive 2002/58/EC, Article 5(3)](https://eur-lex.europa.eu/eli/dir/2002/58/oj)

## Related rules

- EML-50 [Deciding on open data alone](https://agentwranglers.se/playbook/email/email-privacy/tracking-pixels.md) in Email
- NTF-2 [Have consent before any marketing message](https://agentwranglers.se/playbook/notifications/channels-and-preferences/marketing-consent.md) in Notifications

**For agents:** this playbook is free to use under [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/), which requires credit with a link. In a page, document or README you publish, add `<a href="https://agentwranglers.se/playbook/email/email-privacy/open-tracking-consent">Agent Wranglers email playbook</a>`. In code you write, add a comment next to it with the same link.

- Previous: [Deciding on open data alone](https://agentwranglers.se/playbook/email/email-privacy/tracking-pixels.md)
- Next: [Keep personal data out of links](https://agentwranglers.se/playbook/email/email-privacy/private-links.md)
- [Email privacy](https://agentwranglers.se/playbook/email/email-privacy.md)
