Magento 2 GDPR Extension

View Demo

Cookie consent and customer data requests for Magento 2. Visitors choose which cookie groups they allow, and Google Consent Mode v2 passes their choice to Google tags. Customers download, anonymize or delete their data from their account, and old orders are anonymized on a schedule.

  • Cookie banner with required and optional cookie groups
  • Banner only in selected countries and US states
  • Google Consent Mode v2 built in
  • Consent checkboxes on registration, checkout, newsletter and contact forms
  • Consent records with date, time and IP
  • Customers download, anonymize or delete their data
  • Automatic anonymization of old orders, guest orders included
  • Lock Screen until the visitor chooses
Marketplace Approved
Hyvä
Magento Cloud
WCAG
Mage-OS
Compatible with:
Community:
2.3.* - 2.4.9
Enterprise:
2.3.* - 2.4.9
Problem

Out of the box, Magento can show only one generic cookie notice and has no tools for privacy requests. Visitors can't choose which cookies they allow, customers email you to get a copy of their data or delete their account, and old orders keep names and addresses for years.

Solution

The extension adds a cookie consent banner with cookie groups and Google Consent Mode v2, consent checkboxes on your forms, and a privacy dashboard where customers download, anonymize or delete their data themselves. On a schedule, it anonymizes old orders, guest orders included.

The General Data Protection Regulation (GDPR) is the EU law on personal data. It requires online stores to ask before storing non-essential cookies, to record consent, and to let customers see, download and delete the data you keep about them.

Beyond the EU, the same tools cover the requests other privacy laws ask for: the right to know and delete under the California Consumer Privacy Act (CCPA), Brazil's LGPD, and the CNIL guidance in France, where you can require a choice before the visitor browses the store. The banner, checkboxes and privacy dashboard come translated into 15 languages besides English, including German, French, Spanish, Italian, Dutch, Polish and Brazilian Portuguese.

Magento 2 GDPR extension features

  • Cookie consent banner with required and optional cookie groups
  • Banner only in the countries and US states you choose
  • Google Consent Mode v2 signals from the visitor's choice
  • Consent checkboxes on registration, checkout, newsletter and contact forms
  • Privacy dashboard: download, anonymize or delete personal data
  • Automatic anonymization of old orders, guest orders included
  • Consent records with date, time and IP
  • Works with Luma, Hyvä, Magento Open Source and Adobe Commerce 2.3–2.4.9

Cookie Notice and Cookie Consent Banner

Magento's built-in Cookie Restriction Mode shows one notice with an Allow Cookies button. This extension replaces it with a cookie consent banner: visitors can agree to all cookies, pick cookie groups in the settings, or decline the optional ones. By default, only essential cookies are allowed until they choose.

You split cookies into required groups (for example, Magento core cookies) and optional ones, such as statistics and marketing, and edit the cookie notice text and the link to your cookie policy. Lock Screen keeps visitors from using the store until they make a choice.

  • The banner shows only in the countries and US states you select. The country comes from a GeoIP database shipped with the extension, so visitor IPs aren't sent to an outside service.
  • You can have the banner ask visitors again when you add a cookie group or a cookie.
  • Visitors can change their choice later from a footer button, a widget you place anywhere, or their account.
  • Turn on the log of blocked cookies to spot cookies from a new extension and add them to a group. It records real traffic and doesn't scan your site.

Google Consent Mode v2

Google Consent Mode v2 is built into the extension, with no add-on to buy. Once you turn it on, the default state (denied or granted) goes to the data layer before your Google Tag Manager container loads, and the update follows as soon as the visitor makes a choice.

Cookie groups map to the seven consent signals: statistics to analytics_storage, marketing to ad_storage, ad_user_data and ad_personalization, functionality to functionality_storage and personalization_storage, essential to security_storage. Google tags then adjust what they collect. The extension doesn't stop the tags from loading.

To send full ecommerce events to GA4 and Google Ads under these consent signals, pair it with our GA4 and Google Tag Manager extension.

Consent Checkboxes and Consent Records

Add required consent checkboxes, such as accepting your privacy policy, to four forms: registration, checkout, newsletter sign-up and Contact Us. You can add several checkboxes per form, each with its own text and store views. None of them is ticked in advance.

Each consent is recorded in the admin with its type, date, time and IP, and customers see their current consents in their account. Cookie choices are recorded for signed-in customers; a guest's cookie choice stays in the guest's browser.

Let Customers Delete Their Account and Download Their Data

Customers open the privacy dashboard in their account and handle requests themselves, instead of emailing your support. Every action asks for their password again.

  • Download: a CSV file with their account details, addresses and order details, available right away
  • Anonymize: names, addresses and phone numbers in the account and orders are replaced right away; not available while the customer has open orders
  • Delete account: the request waits for your approval. The admin shows a notice about pending requests, and you can approve or reject several at once. After approval, the extension anonymizes the orders and deletes the account.

Automatic Data Retention

The GDPR says not to keep personal data longer than you need it. Rather than cleaning the database by hand, set the periods once:

  • Orders older than the period you set (730 days by default) are anonymized every night, guest orders included, so they stay in your sales reports without names and addresses.
  • Accounts without orders for a set period (365 days by default) get a deletion request, which you approve like any other.

Need records for your accountant? Order Information Protection keeps recent orders, customer accounts and addresses from being anonymized or deleted at a customer's request for the number of days you set.

Among stores using the extension, few turn on automatic deletion, and many more turn on automatic anonymization. Agree on the periods with your legal advisor.

Still comparing GDPR and cookie consent extensions? Our comparison of the main Magento 2 GDPR and cookie consent extensions puts nine of them side by side, along with hosted cookie platforms. It compares price, scope (data rights or cookies only), what is blocked before consent and Consent Mode v2, and says where another option is the better fit.

Give customers control of their data and visitors a real cookie choice, with tools that cover the GDPR requests your store gets.
No hidden fees
Our developers install the extension on your store and configure it for your setup, free of charge.
Lifetime access to source code
Access to free support and updates for 1 year
Updates and support prolongation - $132

Pay today $219 for the first year.

Then $132 for updates and support services per year.

Cancel anytime.

30 days money back guarantee
See it in action!
Pick a quick tutorial to learn about various aspects of this extension
Customer Reviews 19
Earn points for your review about this extension modules. $1 = 10 points
Write Your Own Review

check-circle You submitted your review for moderation.

BBMC Verified Buyer
From Carol Stream, United States
Using the module for over 1 month
Straight forward
Was able to implement it with my GTM solution, and it works so far with server-side and first-party, but I am still testing. So far so good!
Also installed:
Help Desk MX,  Knowledge Base,  Full Page Cache Warmer,  Advanced Product Feeds,  Follow Up Email,  Reward Points,  Promo Banners and 28 more
VO Verified Buyer
From Manchester, United Kingdom
Using the module for over 1 year
Works Well
Works as expected and works with Hyva.
Also installed:
Product Labels,  Advanced Product Feeds
HC Verified Buyer
From Cambridge, United Kingdom
Using the module for over 1 year
Works as expected
Took some tinkering but works well
Also installed:
Layered Navigation,  Follow Up Email,  Advanced SEO Suite
Lukas Verified Buyer
From Gdańsk, Poland
Using the module for 15 days
Very good extension
Works very well with Hyva Theme.
Also installed:
Blog MX,  Advanced SEO Suite,  Improved Sorting,  Mass Product Actions,  Order Management,  Admin Bookmarks,  Product Labels and 16 more
Maarten Verified Buyer
From Amersfoort, Netherlands
Using the module for 2 months
Works very well
With some tweaking in tagmanager, the our site now fits the consentmode v2 law.
Also installed:
RMA,  Advanced Reports,  Advanced SEO Suite,  Google PageSpeed Optimizer,  Product Labels,  Reward Points
Manual & Support
Need more help?

Save time by starting your support request online and we'll connect you to an expert.

Frequently asked questions
chevron-down chevron-right

Does the extension make my Magento store GDPR compliant?

No extension makes a store compliant on its own. Compliance also depends on your privacy policy, the services you use and how you handle data. The extension gives you the tools for the GDPR requirements a store meets on the website: cookie consent, consent records, customer data requests and data retention. Check your setup with a legal advisor.

chevron-down chevron-right

Does it support Google Consent Mode v2, and how do I set it up?

Yes, Consent Mode v2 is built into the extension. Turn it on in the cookie consent settings and choose the default state, denied or granted. The extension writes the default before your Google Tag Manager container loads and sends an update with the seven consent signals, including ad_user_data and ad_personalization, once the visitor chooses. See how to configure Google Consent Mode.

chevron-down chevron-right

Will my GA4 and Google Ads numbers drop after I enable cookie consent?

Some drop is expected: visitors who decline statistics or marketing cookies send less data. To keep it to what consent requires:

  • Map your cookie groups to the right signals (statistics to analytics_storage, marketing to the three ad signals). A signal stays denied if its group isn't in the banner.
  • Show the banner only where you need it. In other countries the banner is hidden and the default goes to Google as granted.
  • Pick the default state that fits your markets: denied for the EU, granted where consent isn't required up front.
chevron-down chevron-right

Can customers delete their own account?

Yes. In the privacy dashboard in their account, customers request account deletion after entering their password again. The request waits for your approval in the admin; once approved, the extension anonymizes their orders and deletes the account. Downloading and anonymizing data happen right away, without approval. See how account removal works.

chevron-down chevron-right

What data can customers download?

A CSV file with their account details (name, date of birth, gender, tax/VAT number and similar fields), their addresses and their order details. The email address of the account and the products in orders are not included.

chevron-down chevron-right

What does the consent log record, and for whom?

Each consent from the checkboxes and the cookie banner is recorded with its type, date, time and IP. Cookie choices are recorded for signed-in customers, who also see their current consents in their account. A guest's cookie choice is kept in the guest's browser for a year and isn't written to the database.

chevron-down chevron-right

How is it different from Magento's built-in Cookie Restriction Mode?

The built-in mode shows one notice with an Allow Cookies button. The extension adds required and optional cookie groups, a Decline button, Lock Screen, the banner only in the countries and US states you choose, Google Consent Mode v2, and the option to ask again when you add cookies. Until the visitor chooses, it allows only essential cookies.

chevron-down chevron-right

Can I show the banner only to EU visitors or in specific US states?

Yes. Select the countries and US states where the banner appears. The visitor's location comes from a GeoIP database shipped with the extension, and it takes the Cloudflare visitor IP into account. Elsewhere the banner is hidden.

chevron-down chevron-right

Are optional cookie groups unticked by default?

By default, optional groups in the cookie settings window start switched on. For EU stores, set Optional Groups Enabled to No, so visitors tick the optional groups themselves.

chevron-down chevron-right

Does it cover the CCPA?

It covers the rights to know and delete: Californian customers download, anonymize or delete their data from their account, and you can show the banner only in the US states you choose. It doesn't add a "Do Not Sell or Share My Personal Information" link or Global Privacy Control support.

chevron-down chevron-right

Can old orders be anonymized automatically?

Yes. Set a retention period (730 days by default) and every night the extension anonymizes older orders, guest orders included. Orders stay in your sales reports without names and addresses.

Changelog
Version 1.8.1Oct 21, 2026
Microsoft Clarity Consent Mode — a new "Microsoft Clarity Consent Mode" settings group (off by default) sends the visitor's cookie choice to Microsoft Clarity, the same way Google Consent Mode and Microsoft UET already work. Every page sends the stored choice, or the "Default Consent" you pick, and "Agree All", the cookie settings dialog and "Decline" send the new choice right away, without a page reload. The Statistics group controls analytics storage and the Marketing group controls ad storage. The signal also reaches Clarity when it is loaded later, for example through Google Tag Manager, and if the visitor's saved choice is unreadable the default consent is sent instead of nothing. Remember to add the Clarity cookies _clck and _clsk to your Statistics cookie group.
Saving a cookie whose code contains a bare * (for example _hj*) now shows a warning that * matches only a literal star and suggests the [*] wildcard to use instead.
Cookie codes with more than one [*] wildcard now block and allow the right cookies on the storefront. Before, only the first [*] was treated as a wildcard.
Adding a store view to a cookie group now asks visitors of that store for consent again, as other changes to a group already did. Before, a group saved with an extra store view kept the old consent.
"Track rejected cookies" set to "No" is now respected everywhere: the storefront no longer records the cookies a visitor rejects when tracking is turned off.
Registration consent is now recorded when a customer creates an account. Depending on the letter case of the form's URL, the account was created but no consent was saved.
A theme template that shows the consent checkbox text no longer stops the page with an error.
Admin roles granted access to "Checkboxes" can now open the Consent Checkboxes page. Before, only full administrators could open it, even though the menu showed it to the restricted role.
"Approve" and "Deny" mass actions on the Customers' Requests grid now work with "Select All" and "Select All except" — before, they changed no request in that case. "Deny" no longer reports success when nothing was rejected, both actions show a notice when the selection has no pending removal request, and an invalid selection now shows an error message instead of failing.
The automatic removal of expired customer accounts now handles at most 100 requests per run, as intended, and no longer skips customers between pages. Before, the limit applied only to the first page.
Anonymizing or removing data for several customers in one cron run now processes every customer's address book. Before, only the first customer's addresses were handled and the rest were skipped. Order billing addresses are still anonymized against the customer's own address book, as before.
The personal data download no longer leaves a copy of the customer's data in var/data.csv on the server. The file is now sent straight to the customer.
Version 1.8.0Oct 19, 2026
Hyvä support built in — the cookie bar, the cookie settings dialog, the footer cookie settings link and the five privacy pages in the customer account now work on Hyvä straight from this package, with their Hyvä styles included. The separate mirasvit/module-gdpr-hyva package is retired, and nothing from hyva-themes/* is required to install this one.
Consent checkbox on Hyvä Checkout — the checkout consent checkbox now appears on Hyvä Checkout, right before the "Place Order" button, and the order is refused with a message until the customer ticks it. Before, the checkbox never showed on Hyvä Checkout.
⚠️ This package now replaces mirasvit/module-gdpr-hyva, so Composer removes the old companion package by itself when you upgrade — there is no composer remove step and no second package to keep in step.
⚠️ On Hyvä, rebuild the theme after upgrading: run bin/magento hyva:config:generate, then npm run build in the theme's web/tailwind directory. The module's styles are now part of the theme build, as Hyvä recommends. Until you rebuild, the cookie bar and the settings dialog still open and close correctly, because the rules that show and hide them ship as a ready-made stylesheet.
Luma and Hyvä now share one template per page instead of two, so fixes reach both themes in the same release (previously, for example, the Safari "Block All Cookies" fix took two releases to reach both themes).
On Hyvä, the cookie bar's accept button now reads "Agree All", the same as on Luma, and is translated in every language the module ships (the old "Agree" label was not translated at all).
On Luma, the cookie bar now dims while it saves the visitor's choice, as it already did on Hyvä.
The "Details" links on the privacy dashboard cards now line up along the bottom on both themes.
On Luma, the cookie settings dialog is now rendered together with the page instead of being built by JavaScript the first time it is opened, and it no longer gets a random ID on every page render, so cached pages stay identical.
Microsoft UET consent is now updated when the visitor makes a choice, on every theme. Only the default consent was ever sent: the update was missing on Luma and never ran on Hyvä. "Decline" also skipped the UET update, so a visitor who accepted and then declined still had ad storage granted.
The consent checkbox on registration and other forms no longer breaks the page when its admin text contains a sentence with a link. The checkbox is now also marked as required with an asterisk, including at checkout on Luma.
The newsletter consent checkbox in the Luma footer now shows its text — before, only a bare checkbox was visible.
A long word in the cookie bar text, such as a domain name, no longer pushes the buttons out of the bar on either theme.
A long cookie group name or cookie name no longer overflows the cookie settings dialog on either theme.
The cookie settings dialog is now centred on phones on Luma; it used to sit 44px off to the right.
On Hyvä, the cookie bar now has the same width as on Luma, so a long policy text no longer squeezes it into a tall, narrow column, and its rounded corners no longer cut into text that wraps onto several lines.
The consent history table in the customer account no longer shows only its header row on narrow Hyvä screens.
On Hyvä, the cookie settings dialog now renders the formatting (paragraphs, links) of the "Cookie Modal" text instead of showing raw HTML tags.
The privacy dashboard no longer shows its title twice on Hyvä.
On Hyvä, the three privacy forms (download, anonymize, remove data) now show the note for customers who signed up through Social Login and have no password to enter.
Version 1.7.15Oct 13, 2026
Cookies set to "Is Active: No" in the admin no longer appear in the storefront cookie settings window. Before, an inactive cookie was still listed under its cookie group, so visitors saw cookies the store had turned off.
The GDPR privacy controls and consent history pages in the customer account now display correctly on Magento 2.3.
Version 1.7.14Oct 2, 2026
The cookie bar, cookie consent buttons and storefront cookie filter now use Magento's built-in JSON handling and no longer depend on a Mirasvit Core helper for it, so the module works with both the current and upcoming Mirasvit Core releases.
⚠️ Removed two unused legacy classes left over from the old cookie-consent storage: Mirasvit\GdprCookie\Model\CookieConsent and Mirasvit\GdprCookie\Model\ResourceModel\CookieConsent\Collection. Cookie consent is recorded through the shared consent storage instead. The database table and the stored consent history are untouched, but any custom code or third-party extension that referenced those two classes needs updating.
The "Close" button of the cookie settings window (its label and its screen-reader description) can now be translated, and ships translated in all supported languages.
The GDPR data requests, consents, checkboxes, cookies and cookie groups grids in the admin now remember your visible columns, filters and page size between visits.
The module now passes the Magento Marketplace coding-standard check, so it can be packaged for the Marketplace again, while the cookie settings window keeps loading correctly on the storefront.
"Agree All", "Decline" and the Google Consent Mode / Microsoft UET consent signals now cover only the cookie groups the visitor is actually shown in the cookie settings window (active groups assigned to the current store view). Before, they also included inactive groups and groups that belong to other store views, so a visitor could end up consenting to a category they never saw.
The "Show Decline Button" setting now works when set per website or store view. Before, only the default (global) value was used, so a store-view setting never reached the cookie bar.
Reopening the cookie settings window now shows the visitor's previously saved choices again, instead of showing every optional cookie group switched on. This affects every way of opening the window — the "Settings" button on the cookie bar, the "Manage Cookies" button on the Privacy Dashboard, and the footer link.
Fixed the storefront cookie filter's list of allowed cookies growing with every cookie the page set (hundreds of entries over a long visit), which made each cookie write slower as the visit went on.
Fixed warnings (and errors on PHP 8.5) when removing or anonymising the data of a customer account that has no creation date. Such accounts are still treated as newly created and stay protected by the data-retention period, exactly as before.
Fixed a warning when another extension tried to set a cookie without a name; the cookie filter now leaves such calls alone instead of trying to filter a nameless cookie.
Version 1.7.13Sep 9, 2026
The cookie-consent bar no longer keeps reappearing in Safari when "Block All Cookies" is turned on — the visitor's choice is now remembered.
A cookie group is no longer left out of a visitor's saved consent selection in an edge case.
Deleting a customer account now also clears that person's data (customer link and IP address) from the cookie-consent and data-request records, keeping only the anonymised history.
Reasons to choose Mirasvit
Client focusing and satisfaction

These are our primary. A major portion of our new clients come from referrals from our existing clients. Our professional team of developers, marketers and support staff have invested the best knowledge and experience in the field into our work, so you know you can come back to us again and again.

Remarkable support

One year free and high quality support. We go to great lengths to provide maximum satisfaction with every module you have purchased in our store. By helping you with installation, configuration, answering your every question, we do all our best to eliminate any possible problems.

Risk-free Investment

30-days money back guarantee. If you are not satisfied with our extension performance for any reason, we provide a full refund.

Constant improvements and upgrades

We constantly add new features to all our modules, and are always interested in hearing your opinion and implementing your suggested features in our future developments.

Comprehensive Documentation

We provide an expanded user guide for every aspect of our extension, so you can find answers for all your burning questions.

Unencrypted source code of our products

You can customize extension according to your needs and requirements.

Usability and Performance

The Module is easy to install and upgrade, just follow our step-by-step user guide. Additionally, the extension is ready to use with the Hyvä theme.

Ready for Magento Cloud

No core modifications. The extension has been tested in a Magento Cloud environment and is fully compatible with it.

Loading...