Skip to main content

Every website use cookies that generate small-sized files that store information like users’ movements, email addresses, phone numbers, and other data visitors enter browsing a website. Many countries have different legislation related to cookies, and every online merchant has to keep peace with acts like GDPR and CCPA. According to these acts, every website must obtain customer consent for collecting their personal data. Today, we’ll learn everything about Magento | Adobe Commerce cookies configuration.

Cookies Configuration in Magento | Adobe Commerce


First of all, we need to enable Cookie Restriction Mode to notify visitors that your store collects cookies and obtain their consent. 

  1. Go to Stores > Settings > Configuration.
  2. In the left panel under General, choose Web.
  3. Expand the Default Cookie Settings section and fill the next fields:

Cookie Lifetime.  Set how long Cookie files stay in the user’s browser. The default setting is one hour which equals 3600 seconds.    

Cookie Path. Enter the path if you want to make cookie files available to other folders. Enter a forward slash “/” to make cookies available everywhere on the site. 

Cookie Domain. Enter a subdomain name to make the cookies available to a subdomain.  To make cookies available to all subdomains, enter the domain name preceded by a period (.yourdomain.com).

Use HTTP Only. Select Yes to prevent JavaScript or other scripting languages from gaining access to cookies.  

Cookie Restriction Mode. Select “Yes”.

Cookies-Configuration-in-Magento-2-768x234-1 How to Edit and Configure Cookies in Magento | Adobe Commerce

Privacy Policy Update

1. Content > Pages > Privacy Policy > Action > Select > Edit 

 

How-to-edit-privacy-policy-in-Magento-2-1024x418-1 How to Edit and Configure Cookies in Magento | Adobe Commerce

2. Expand the Content section and make changes to the default Luma Privacy Policy.

Updating-Privacy-Policy-in-Magento-2-1024x488-1 How to Edit and Configure Cookies in Magento | Adobe Commerce

If you change the URL key of the privacy policy page, you must also create a custom URL rewrite to redirect traffic to the new URL key. Otherwise, the link in the footer will return “404 Page Not Found.”

3. Save.

How to Edit Cookies in Magento | Adobe Commerce


1. Go to Content > Pages > Enable Cookies > Select > Edit

2.  Here you can edit the next aspects:

Edit-Cookies-in-Magento-2-1024x448-1 How to Edit and Configure Cookies in Magento | Adobe Commerce

Top Cookie Extensions for Magento | Adobe Commerce

If you want your store to be fully compliant with cookie laws like GDPR and CCPA, you’ll need a more complex solution to configure and manage cookies.

Cookie Consent for Magento 2 by Amasty

Amasty’s Cookie Consent extension allows implementing a more detailed cookie bar to enhance data protection and improve user experience. The solution ensures your compliance with Cookie Legislation requirements to avoid penalties for breaching them.

Remarkable features:

  • Provide customers with selective consent
  • Let customers revoke consent
  • Split cookies between categories
  • Assign cookies to customer groups
  • Block 3rd-party cookies
  • Inform users about the changes in cookie
  • Show cookie bar according to location

Cookie Consent Extension by Plumrocket

Plumrocket’s Cookie Consent extension is fully compliant with GDPR, CCPA, LGPD (Brazil’s federal data privacy law), and other local data privacy laws. The extension allows to display cookie banner and request customer consent, customize cookie settings by turning on/off specific cookie categories and fully control cookie management.

Remarkable features:

  • Customizable cookie banners (“Bottom Cookie Banner”, “Cookie Consent Popup”, and “Full-Screen Cookie Wall”, colors of the buttons, backgrounds, text styles, etc.)
  • Create additional cookie categories or modify existing, add descriptions, change cookie panel design, and more
  • GeoIP functionality
  • Block cookies from footer & header scripts, default Magento cookies
  • Built-in support of all default Magento cookies and cookies created by the Plumrocket extensions

Have Any Questions or Need Help with Installation?

Alex Yermak

Alex Yermak

Content Manager at Mobecls