
In short
GA4 data redaction removes email addresses and URL query parameters you choose from web data before it is sent to Google Analytics, replacing them with "(redacted)". It is on by default for email in new properties. This guide shows how to set it up and test it, what it misses and which other GA4 privacy controls to use alongside it.
Contents8 sections
Analytics data should never contain personal information such as email addresses. Yet it often slips in, for example through a "thank you" page URL that includes the email address a visitor typed into a form. GA4 data redaction is a safety net that removes this kind of personally identifiable information (PII) before it reaches Google Analytics.
What is GA4 data redaction?
Data redaction is a setting on GA4 web data streams. It finds email addresses and the URL query parameters you specify and removes them on the user's browser, before the data is sent. The removed text is replaced with (redacted) and data collection carries on as normal (Google's data redaction guide).
What can you redact?
- Email addresses: GA4 uses text patterns to detect likely email addresses in all event parameters. For new properties this is on by default.
- URL query parameters: you list parameter names, such as
firstnameoremail_address, and GA4 redacts their values in page_location, page_referrer, page_path, link_url, video_url and form_destination.
Why use data redaction?
- User privacy: keeping PII out of analytics shows users you take their data seriously.
- Regulations: laws such as GDPR and CCPA make collecting PII risky. Redaction lowers the chance of collecting it by accident.
- Policy: Google Analytics policies don't allow sending PII, so redaction is a useful backstop.
- Cleaner data: your reports hold only the data you meant to collect.
How do you set up data redaction in GA4?
You need the Editor role or above on the property.
- In Admin, under Data collection and modification, click Data streams.
- Click the web data stream.
- In the Events section, click Redact data.
- Turn on the switch for email addresses, URL query parameters or both.
- If you chose query parameters, enter each parameter name you want to redact (for example firstname, lastname, email_address), pressing Enter after each one.
How do you test it?
Use the Test data redaction section on the same screen:
- Enter sample text with an email address, or a URL with the query parameters you listed, for example
https://www.example.com/settings?firstname=John&lastname=Doe&[email protected]. - Click Preview redacted data.
The redacted version shows what Analytics would collect. For the sample above, it would be:
https://www.example.com/settings?firstname=(redacted)&lastname=(redacted)&email_address=(redacted)
What does data redaction not catch?
- Best effort only: email detection works on patterns. Text with an "@" followed by a domain ending may be redacted even when it isn't an email address.
- Limited scope: it doesn't detect other PII such as names or phone numbers unless they sit in a query parameter you listed.
- Web only: it works on web data streams, not app streams.
- Other data routes: it doesn't stop PII sent through the Measurement Protocol or Data Import, and it doesn't check HTTP header values such as the referer.
Responsibility for meeting privacy rules stays with you, so fix the source of any PII (forms that put emails in URLs, for example) rather than relying on redaction alone.
Best practices
- Keep email redaction on. Email is the most common PII leak.
- Audit your URLs. Look for query parameters that carry names, emails or IDs and add them to the redaction list.
- Test before relying on it. Use the preview tool, then check a staging site to make sure nothing you need is removed.
- Monitor reports. Watch for unexpected "(redacted)" values or missing data after you change settings.
What other GA4 privacy controls should you use?
Data deletion requests
If personal data has already been collected, a data deletion request removes it. In Admin, under Data collection and modification, open Data deletion requests. You can delete all parameters, selected parameters or selected user properties. Deleted text is replaced with "(data deleted)". There is a 7-day grace period to cancel, processing can take 7 to 63 days, and only data older than 12 days can be deleted (Google's data deletion guide). To delete data for an individual user, use User explorer or the User Deletion API.
Consent with Google Tag Manager
Google Tag Manager is where most sites connect their cookie banner to their tags. A consent management platform (CMP) records each visitor's choices, and Google's consent mode passes them to Google tags. In basic consent mode, tags don't load until the visitor agrees. In advanced consent mode, tags load but send cookieless pings when consent is denied. For non-Google tags, use GTM's consent settings or triggers so they fire only when the right consent is given. Our consent mode v2 guide covers the setup.
IP addresses
GA4 does not log or store IP addresses, so unlike Universal Analytics there is no IP anonymization setting to switch on.
Regular privacy audits
- Review your GTM container and remove tags you no longer need.
- Review GA4 data collection settings when regulations or your site change.
- Keep your privacy policy and cookie notice clear about what you collect and why.
For tighter control, some teams also route tags through server-side tagging, which lets them strip data before it reaches any vendor.
Conclusion
GA4 data redaction is a simple, useful layer of protection for web data. Turn it on, test it and combine it with deletion requests, consent mode and regular audits. It is one piece of the privacy puzzle, so check your overall data collection with a privacy professional.


