Integrate CookiePal with React

Welcome to CookiePal! This guide will walk you through how you can install a cookie banner on your website.

technology icon

Integrate Cookiepal with React

CookiePal helps you ensure your React application complies with GDPR and other privacy laws by managing cookie consent for your users. This guide will walk you through the steps to integrate CookiePal with your React application.

Step-by-Step Guide

Step 1: Sign in to CookiePal

Sign in: Go to CookiePal and sign in to your account.

Step 1: Sign in to CookiePal Image

Step 2: Get the Installation Code

Generate Code: In your CookiePal dashboard, click on the HTML file icon to get the installation code. Refer to the gif below for detailed instructions on how to do this.

Step 2: Get the Installation Code Image

Copy Code: Copy the generated script code to your clipboard.

Step 3: Add the CookiePal Script to Your React Application

Include Script: Open your React application and locate the public/index.html file.

Insert Script: Paste the CookiePal script code you copied earlier into the <head> section of the index.html file.

Step 3: Add the CookiePal Script to Your React Application Image

Step 4: Initialise CookiePal in Your React Application

Save Your Changes: Save your changes using your preferred code management tool.

Deploy Your Website: Deploy this new version of your website using your preferred methods and automation.

Step 5: Verify the Cookie Banner

Verify Banner: Return to the CookiePal dashboard and verify that the cookie banner is active on your website. The status should change to "Active".

Step 5: Verify the Cookie Banner Image

Test Implementation: Visit your website to ensure the cookie consent banner appears correctly and cookies are blocked until user consent is given.