Skip to content

Quick Start

This guide walks you through installing the eConsent tracker on your website and capturing your first consent certificate.

Getting Started with eConsent

Step-by-step walkthrough of creating your account, adding a property, installing the tracker, and capturing your first certificate.

~5 min
  • An eConsent account (sign up at econsent.org)
  • Your Company ID and Property ID (found in the dashboard under Settings)
  • Access to your website’s HTML or Google Tag Manager
  1. Create a property in the dashboard

    Log in to app.econsent.org and navigate to Properties. Create a new property by entering your website’s domain (e.g., https://example.com). Save the property to receive your unique Property ID.

  2. Install the tracker script

    Add the eConsent tracker to your website. Replace COMPANY_ID and PROPERTY_ID with your actual values.

    1. Open your GTM container and create a new Custom HTML tag.
    2. Paste the following code:
    <script src="https://d13jv0uulndum1.cloudfront.net/cdn/tracker.min.js"
    data-company="COMPANY_ID"
    data-property="PROPERTY_ID">
    </script>
    1. Set the trigger to All Pages (or limit to pages with consent forms).
    2. Publish the container.

    Google Tag Manager setup with eConsent script

    Integration page showing Company ID and Property ID

  3. Tag your consent elements

    Add data-consent-type attributes to your consent language and checkboxes:

    <!-- Primary consent language (always visible) -->
    <p data-consent-type="main-implied">
    By submitting this form, you consent to receive marketing communications.
    </p>
    <!-- Primary opt-in checkbox -->
    <input type="checkbox" data-consent-type="main-explicit" />
    <!-- Add a hidden field to receive the certificate ID -->
    <input type="hidden" id="econsent_hidden" name="econsent_hidden" value="">

    The tracker automatically populates the hidden field with the certificate ID on form submission.

  4. Verify the installation

    Open your website in a browser and submit a test form. Then:

    • Check the browser console for eConsent initialization messages.
    • Look for the econsent_session and econsent_certificate cookies.
    • In the eConsent dashboard, navigate to Certificates to see your first captured consent event.
  5. Configure verification (optional)

    To verify certificates programmatically, call the Verification API:

    Terminal window
    curl -X POST https://api.econsent.org/api/verify/match \
    -H "Content-Type: application/json" \
    -d '{
    "certificate_id": "YOUR_CERTIFICATE_ID",
    "company_id": "COMPANY_ID",
    "property_id": "PROPERTY_ID",
    "consent": "By submitting this form, you consent to receive marketing communications."
    }'

Once the tracker is installed, eConsent automatically:

  • Captures session recordings using rrweb for full DOM replay
  • Extracts consent elements from tagged HTML elements
  • Generates tamper-proof certificates with HMAC-SHA256 cryptographic signatures
  • Auto-populates the hidden form field with the certificate ID
  • Tracks core PII (name, email, phone, address) with hashing
  • Records metadata including IP address, user agent, geo-location, and browser language

After a form submission, the certificate ID is available in three ways:

// JavaScript API
window.econsentState.session_id // Session ID
window.econsentState.certificate // Certificate ID
<!-- Hidden form field (auto-populated) -->
<input type="hidden" id="econsent_hidden" name="econsent_hidden" value="">

The tracker also sets two cookies: econsent_session and econsent_certificate.