1Consent Docs

Getting started

Install the 1Consent loader, configure how your tags wait for consent, and verify the published release.

Working with an AI assistant? Connect Lovable, Cursor, Claude, Codex or ChatGPT to retrieve your site's installation settings and verify its access before editing your project.

Add your site

Start free or open the 1Consent Dashboard, then add a site for your website.

Name the site after your website. Choose GDPR or US Privacy for a banner you can publish, then add the services you use. On Starter and Pro, IAB TCF is available only for configuration and preview in the signed-in Dashboard.

Copy the script tag

Open Install & verify in the site navigation. Copy the Preview loader for your test site. Keep it synchronous when required by your framework and follow the setup instructions shown for your site.

If you have several drafts and the site does not have published routing, use the Preview instructions to select the intended framework explicitly.

Add it to your test site

Put the copied loader in <head> before the scripts it governs. For manual blocking, put each governed script inside an inert template and use the matching configured service tag. For example, if your Analytics service tag is google-analytics:

<head>
  <script src="https://cmp.1consent.app/id/YOUR_APP_ID.preview.js"></script>
  <template data-1c-service-tag="google-analytics">
    <script src="https://www.googletagmanager.com/gtag/js?id=G-XXXXX"></script>
  </template>
</head>

Use your own Preview URL, service tag and measurement ID. Move any equivalent initialization into the governed setup as well. For automatic blocking, configure Automatic Setup for the site and verify its coverage instead.

Verify it works

On the test site, use a fresh browser session. Check the Network and Storage panels before making a choice and after rejection. Optional tags and their storage should remain blocked in both cases. Then reopen preferences, grant the matching service and confirm the expected request starts. Withdraw consent and check subsequent activity, including after reload.

Record what you tested and what you could not check. Test pages that require a sign-in separately in a browser session that can access them.

Review and publish

Open Banner in the Dashboard, then choose Review & publish. Review the changed configuration, target stage, and whether returning visitors need to choose again. Adding services, categories or purposes, or making a service always on, can call for a fresh choice. Review the changes and the re-consent recommendation for this release.

Confirm publication with an account that has publishing permission. If you use Pro Staging, test the release there before promoting it to Live. Once the release finishes deploying to Live, install the Live loader from Install & verify on your production website and repeat the checks there. To record automated browser checks in Install & verify, select an eligible saved domain after the Live website release is fully deployed.

Using WordPress or Next.js? Check the Integration Guides for platform-specific setup instructions.

Building an app? Add it to the same site and follow the Native apps guide for Android, iOS and Expo.

How script blocking works

Autoblocker (automatic)

Automatic Setup uses the domains in the 1Consent catalogue to identify scripts for the services in your published banner that require consent. It holds matching scripts until the visitor grants consent. In Services & cookies, look for services marked “Not blocked automatically”. Gate their scripts with a template.

Template blocking (manual)

Use a template with the service tag configured in your Dashboard when you need explicit control over which scripts and resources wait for consent. See Gate third-party scripts for the full pattern.

Next steps

On this page