> For the complete documentation index, see [llms.txt](https://docs.avada.io/cookie-help-center/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.avada.io/cookie-help-center/integrations/integrate-with-google-consent-mode.md).

# Integrate with Google Consent Mode

Hello there! We're here to guide you through the process of integrating Google Consent Mode with Avada Cookie Consent. Google Consent Mode allows you to adjust how Google services operate based on the consent status of your visitors. This guide will walk you through the steps to make this integration happen. Don't worry, we'll be with you every step of the way!

### Step 1: Setting Up for Integration[​](https://help.avada.app/cookie/how-to-integrate-with-google-consent-mode/#step-1-setting-up-for-integration) <a href="#step-1-setting-up-for-integration" id="step-1-setting-up-for-integration"></a>

First things first, please ensure that you've set up GA4 or GTM on your store. If you haven't done this yet, no worries! You can follow the instructions [here](https://support.google.com/tagmanager/answer/12002338?hl%3Den) to get that sorted out.

**A. For NEW users that haven’t used integration with GCM through the Avada Cookie app, the process is:**

Once that's done, please navigate to your <mark style="color:blue;">Shopify admin > Online store</mark>&#x20;

From there, select **'Edit code'** from the Actions dropdown button.

<figure><img src="/files/vHz7iAmMke8K6z6M8ZPi" alt=""><figcaption><p>Edit code</p></figcaption></figure>

Next, select the **'Asset'** folder > Choose 'Add new asset' and upload the file 'avada-cookiebar-gcm-integration.js'. You can download the file below

[**avada-cookiebar-gcm-integration.js**](https://firebasestorage.googleapis.com/v0/b/avada-cookie.appspot.com/o/integration%2Favada-cookiebar-gcm-integration.js?alt=media\&token=69df3b83-9e7b-4f53-a4d7-e3fd20edcad9)

<figure><img src="/files/D4MD55d1jWrVvYEoKIMe" alt=""><figcaption><p>Add js file</p></figcaption></figure>

Now, open the **'theme.liquid'** file in the **'Layout'** folder. Look for the opening tag of the HTML head element - `<head>` in the 'theme.liquid' file.

<figure><img src="/files/cnvUlMcK1Za2Wkn9VJK1" alt=""><figcaption><p>Paste code</p></figcaption></figure>

Copy the code provided below and paste it as close to the opening head tag (`<head>`) as possible.

```
<script async src="{{ 'avada-cookiebar-gcm-integration.js' | asset_url }}"></script>
```

Please ensure to place the GCM code before other tracking tools like GTM/GA.

**B. For EXISTING users that have already used integration with GCM through the Avada Cookie app, please follow the instructions below:**

* Open <mark style="color:blue;">Shopify Admin > Online store</mark>
* Click on the Actions dropdown button and select Edit Code from there.
* From the Assets section, locate the existing file avada-cookiebar-gcm-integration.js and delete it. You could also delete that file from your device to avoid using the old file.
* Upload the new file 'avada-cookiebar-gcm-integration.js'

### Step 2: Integrating with Google Consent Mode V2[​](https://help.avada.app/cookie/how-to-integrate-with-google-consent-mode/#step-2-integrating-with-google-consent-mode) <a href="#step-2-integrating-with-google-consent-mode" id="step-2-integrating-with-google-consent-mode"></a>

Now, let's head back to the Google Consent Mode V2 integration screen.&#x20;

<mark style="color:blue;">Click on Integrations (GCM V2, Tiktok, Pixel) > Google Consent Mode V2</mark>

Click **'Turn on'** to integrate your store with GCM.

<figure><img src="/files/sG0wIQavQrRpeSw3BLpD" alt=""><figcaption><p> Google Consent Mode V2</p></figcaption></figure>

Once the integration is successful, you can choose **'Turn off'** at any time to stop the integration with Google Consent Mode.

And there you have it! You've successfully integrated Google Consent Mode with Avada Cookie Consent. If you have any questions or run into any issues, don't hesitate to reach out. We're here to help!


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.avada.io/cookie-help-center/integrations/integrate-with-google-consent-mode.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
