Setup & Installation
Welcome to the Consentify documentation. Here you'll find all the information you need to install, configure, and customize the consent banner for your website. Our goal is to make GDPR compliance as simple and seamless as possible.
Setup & Installation
Welcome to the Consentify documentation. Here you'll find all the information you need to install, configure, and customize the consent banner for your website. Our goal is to make GDPR compliance as simple and seamless as possible.
Revoke Consent Button
To comply with GDPR and allow users to change their cookie preferences at any time, you must add a revoke consent button to your website. When clicked, this button reopens the Consentify banner so users can update their settings.
⚠️ Required for compliance
This button must be present and accessible on all pages where the Consentify banner is active. If you cannot add the button to certain pages (like checkout or payment pages), you must exclude those routes in your dashboard settings.
How it works
The Consentify script automatically detects any element with the id revoke-consent-btn and attaches the necessary click event to it. No additional JavaScript required on your end.
Implementation
Add this button to your site's footer or another persistent location that appears on all pages:
<button id="revoke-consent-btn">
Cookie Settings
</button>You can style this button with your own CSS classes to match your website's design. The text can also be customized to match your preferred language (e.g., "Cookie Preferences", "Manage Cookies", etc.).
Alternative: Exclude routes
If there are specific pages where you cannot include the revoke consent button (such as checkout flows, payment pages, or embedded forms), you can exclude those routes in your Consentify dashboard. This tells our system to skip compliance checks for those specific paths.
No JavaScript required!
The Consentify script handles everything automatically. Just add the HTML element with the correct ID, and it will work immediately.
Integrations
Consentify makes it easy to integrate with popular third-party services like Google Analytics, Facebook Pixel, and many more. Our system ensures that these scripts are only loaded after a user provides their explicit consent, helping you maintain GDPR compliance.
How Integrations Work
When a user gives consent for a specific category (e.g., Analytics or Marketing), Consentify dynamically injects the associated third-party scripts into your website. This means you don't need to manually manage conditional script loading – Consentify handles it for you automatically.
For each integration, you typically provide an ID (e.g., a Google Analytics Tracking ID or a Facebook Pixel ID) in your Consentify dashboard. Our system then renders the correct script for that service.
Supported Integrations
Consentify supports a wide range of popular services. You can enable and configure them directly from your dashboard under the 'Integrations' tab.
View IntegrationsTips & Tricks
How to See the Banner Again
Once a user has made a choice, the Consentify banner will not automatically reappear on subsequent visits, unless the policy version changes or the consent expires. If you need to test the banner or change your consent, here are a few ways:
- 1. Clear Local Storage: The easiest way to force the banner to reappear is to clear the `csfy_consent` item from your browser's Local Storage for your domain. You can do this in your browser's developer tools (Application -> Local Storage).
- 2. Use Incognito/Private Browsing: Opening your website in an incognito or private browsing window will treat you as a new visitor, causing the banner to display.
- 3. Programmatic Reopening: The Consentify script exposes a global function `window.consentifyReopenBanner()` that you can call from your browser's console or your own JavaScript to force the banner to show again.
Policy Versioning
Consentify uses a policy versioning system. If you update your cookie policy or make significant changes to your banner configuration in the dashboard, incrementing the 'Policy Version' will ensure that all users see the banner again and are prompted to re-consent, even if they previously accepted.
Local Storage Key
Consentify stores user consent preferences in your browser's Local Storage under the key `csfy_consent`. The stored data includes preferences for necessary, analytics, and marketing cookies, along with the `policy_version` and a `delete_token`.
Debugging the Banner
Consentify provides several built-in mechanisms to help you debug the banner and integration scripts.
Debug Modes (GTM Preview, Hotjar Verify)
The Consentify script automatically detects certain URL parameters that are commonly used by debugging tools like Google Tag Manager (GTM) Preview mode or Hotjar Verify. When these parameters are present, Consentify will activate all integration scripts regardless of the user's consent, allowing you to test your tracking setups.
- For GTM Preview mode, look for parameters like `gtm_preview`, `gtm_auth`, or `gtm_debug`.
- For Hotjar Verify, look for `hjVerifyInstall` or `hjVerifyUUID`.
Development Domain Validation Bypass
In development environments (`NODE_ENV === "development"`), Consentify automatically bypasses domain validation. This means you can test the banner on `localhost` or any development URL without needing to register it in your dashboard.
Pageview Tracking
Consentify tracks pageviews for billing and analytics purposes. The script increments a pageview counter via an API endpoint (`/api/gateway/increment-pageview`). This happens automatically on initial page load and on subsequent route changes (for SPAs) if consent is given or pre-authorized.