For the complete documentation index, see llms.txt. This page is also available as Markdown.

Cross Site Verification

This guide explains how AgeGO allows verified users to be automatically recognized across multiple AgeGO-enabled sites.

It covers how verified links work, how verification tokens are generated, and how to implement cross-site verification securely and respecting regulations.

Overview

AgeGO Cross-Site Automatic Verification allows users who have already verified their age on one AgeGO-enabled site (Site A) to be automatically recognized as verified when they click on a link going to another AgeGO-enabled site (Site B).

It is designed to reduce repeated verification prompts while staying compliant and privacy-friendly.

This mechanism uses a short-lived, single-use verification token called ag_token. Tokens are prepared in the background and attached to the destination URL when the user clicks through; if the prepared token has already expired by then, a fresh one is generated at the moment of the click. Site B must also run the AgeGO script, since it is the script on Site B that reads and validates the token.

How the token gets attached depends on your setup. If the link is served by an AgeGO partner such as ExoClick, the partner's ad script handles it and nothing is needed on your side (partner integration). If you build the links yourself, you use the AgeGO JavaScript helpers to attach the token, and you call AGEGO('prefetchToken') once on page load so the first click does not have to wait for one (manual integration, see Option 2).

Why This Matters

Using verified links helps:

  • Prevent repeated age-verification flows.

  • Reduce friction for returning users.

  • Maintain regulatory compliance across linked sites.

  • Preserve user privacy (no third-party cookies involved).

Key Benefits

  • Robust by design: The verification status is not passed as “trust me.” It is validated server-side through AgeGO.

  • Short-lived: Tokens expire after a few minutes, so they are only useful around the click-through moment.

  • No cookies required: This mechanism does not rely on third-party cookies and can thus be used in cookie-restricted or incognito/private browsing environments.

  • Hard to bypass: Tokens are single-use and validated by AgeGO servers. Even if copied, they expire quickly and cannot be reused after validation.

A verified link is a standard website link that includes an AgeGO Verification Token (ag_token).

Example:

When a verified user clicks through from Site A to Site B, the AgeGO script on Site B reads and validates the token. If valid, the user is granted access without repeating verification.

How It Works (High-Level)

1

User verifies on Site A.

2

While the page loads, the AgeGO script (or the partner ad script) requests a verification token in the background, so one is ready before any click happens.

3

User clicks a link or ad going to Site B.

4

The ready token is appended to the destination URL as ag_token. If no valid token is available at that moment (for example it has expired or was already used), a new one is generated at the moment of the click.

5

From Site B, AgeGO validates the token.

6

If valid, user is instantly recognized as verified.

Tokens are single-use: once one is consumed, a new one is prepared in the background for the next click. If a token cannot be obtained in time, the user is redirected normally without one — the click is never blocked — and verifies on Site B as usual.

Security Design

Cross-site Automatic Verification includes several security safeguards:

  • Not proof of age: The token itself is not the proof of age. It’s a secure, single-use “ticket” that allows Site B to fetch verification status from AgeGO.

  • Single-use: Once successfully validated, the token is immediately invalidated and cannot be used again.

  • Short TTL: Tokens expire after a few minutes, making them useless if copied and passed to another user.

  • Fresh generation: Tokens are prefetched in the background as the page or ad loads, or generated at click time, and are only held briefly in the browser — never stored long-term.

  • No third-party cookies: Does not depend on cross-site cookies or third-party tracking.

Implementation Options

AgeGO supports two implementation options for cross-site verification. Choose the one that best fits your setup.

  • If you work with an AgeGO partner integration (e.g. ExoClick), start with Option 1: Automatic Integration.

  • If you want to create verified links yourself, start with Option 2: Manual Integration. This option includes two approaches:

    • Option A for the simplest setup.

    • Option B for advanced or dynamic use cases.

No demo environment is required.

All examples can be tested directly on your staging or production environment.

Who is This For?

Publishers using partner ad networks with direct AgeGO integration, such as ExoClick.

How Does it Work?

  • No manual implementation is required.

  • AgeGO and ExoClick handle everything automatically.

What Happens Behind the Scenes?

1

A partner ad is displayed on your site.

2

The partner script requests a verification token in the background while the ad is displayed.

3

The user clicks on the ad.

4

The script adds the ready token to the ad’s destination URL — or generates one at the moment of the click if no valid token is available.

5

The user is redirected as usual.

Do I Need to Enable This?

  • No — Cross-Site Automatic Verification is enabled by default for all AgeGO sites. No action is needed on your side.

If you would like this feature disabled for one of your sites, contact your AgeGO account manager.

Option 2: Manual Integration

Use this option when you want to create verified links yourself, without relying on an automatic partner integration.

Within the manual approach, AgeGO supports two implementation patterns, depending on how much control you need. AgeGO provides simple JavaScript functions to support this.

Whichever pattern you use, call AGEGO('prefetchToken') once on pages that contain verified links. This prepares a token in the background and keeps it fresh while the user is on the page, so the token is ready at click time. Without it, the first click waits briefly for a token to be created (up to 1.5 seconds by default) before redirecting.

Option A: All-in-One Automatic Redirect (Easiest)

Who is this for?

Publishers who want the simplest and safest implementation.

What this does

1

Generates the verification token.

2

Appends it to the destination URL.

3

Redirects the user automatically.

All in one step.

An optional parameter, openInNewTab, controls how the redirect is opened. By default, it is set to false, meaning the redirect occurs in the current tab. If set to true, the redirect will open in a new browser tab.

Example:Button:

Example Link:

Key Benefits

  • Only the destination URL needs to be replaced.

  • Ideal for “Continue”, “Enter”, or “Visit Site” buttons.

  • Recommended for most publishers.

Option B: Token-Only Generation (Advanced)

Who is this for?

Publishers with:

  1. Custom JavaScript logic.

  2. Dynamic pages.

  3. Multiple verified links per page.

How it works

1

Your site requests a verification token from AgeGO.

2

The token is added to the destination URL.

3

The user is redirected to the destination.

If you only need the destination URL with the token attached, AGEGO('getTokenUrl', url) does steps 1 and 2 for you: it resolves to url with ag_token appended, or to url unchanged if no token could be obtained, and never rejects.

Example JavaScript:

Implementation href and button

In this example, the publisher’s script:

  1. Requests a verification token from AgeGO.

  2. Appends the token to the destination URL if available.

  3. Redirects the user accordingly.

If token generation fails, the user is redirected normally without interruption.

Important: Intermediate Redirects

Last updated

Was this helpful?