In a Web Experiment, Pages control where your experiment variants apply on your site. They help scope experiments to specific URLs, enabling you to run tests on targeted pages, without impacting unrelated parts of your site.
A Page defines the conditions under which a web experiment applies to your site, and includes:
When you create a new Web Experiment, specify a page by:
After you add the page, continue with experiment setup, or go directly to the Visual Editor.
You can update or create another page to any Web experiment.
| Operator | Description | Examples |
|---|---|---|
| URL Matches | Match the page URL, ignore query parameters or hash fragments. | https://example.com/pricing ✅ https://example.com/pricing#details ❌https://example.com/pricing/enterprise |
| URL Matches Exactly | Match the full page URL exactly. | https://example.com/pricing?utm_source=facebook ❌https://example.com/pricing ❌ https://example.com/pricing?utm_source=tiktok |
| URL Matches Pattern | Match the full page URL, including wildcards (*). |
https://example.com/blog/* ✅ https://example.com/blog/my-first-post ✅ https://example.com/blog/my-second-post#get-started |
| URL Contains | Match the full page URL, where the URL contains a specific substring. | /blog/my-first ✅ https://example.com/blog/my-first-post ❌ https://example.com/blog/my-second-post |
| URL Starts With | Match the full page URL, where the URL starts with an exact substring. | https://example.com/blog ✅ https://example.com/blog/my-first-post ❌ https://example.com/pricing |
| URL Ends WIth | Match the full page URL, where the URL ends with an exact substring. | /blog/my-first-post ✅ https://example.com/blog/my-first-post ❌ https://example.com/blog/my-first-post#get-started |
| URL Matches Regex | Match the full page URL with a regular expression you define. | Learn Regex Test Regex |
Page triggers define when an experiment evaluates a Page's conditions to determine whether the experiment activates on a webpage. Although page targeting rules determine where an experiment runs, page triggers determine when variant actions apply.
When you create a new experiment, the default trigger type is Immediately. Immediate triggers evaluate the page conditions whenever the URL changes (including initial page load). You can configure different trigger types to control when your experiment activates based on user behavior, page events, or custom conditions.
| Trigger Type | Description | Parameters |
|---|---|---|
| Immediately | Evaluates when the URL or route changes. | None |
| On Event Tracked | Evaluates when a specific Amplitude analytics event occurs. If you don't load Analytics and Web Experiment together through the unified script tag, call window.amplitude.add(window.webExperiment.plugin()) to ensure the web experiment client receives tracked event notifications. |
Event name. Optional property filters to match specific event property values. |
| When Element Appears | Evaluates when an element matching a CSS selector appears in the DOM. | CSS selector of the element. |
| When Element Becomes Visible | Evaluates when an element becomes visible in the viewport. | CSS selector of the element. Optional visibility ratio (0-100) that defines how much of the element must be visible. |
| After Time on Page | Evaluates after the user spends a minimum amount of continuous time with the page in focus. | Duration in seconds. |
| When User Exits | Evaluates when the cursor moves upward toward the top of the viewport. | Optional minimum time (in seconds) the user must spend on the page before exit intent can trigger. |
| When Scrolled To | Evaluates when the user scrolls to a specific element or scroll percentage. | Element mode: CSS selector and pixel offset from the bottom of the viewport. Positive values trigger before the element enters view, negative values trigger after the element is partially visible. Percent mode: Percentage of page scrolled (0-100). |
| When User Interacts | Evaluates on click, hover, or focus of a specified element. | CSS selector of the element. Interaction type (click, hover, or focus). Optional time threshold in milliseconds. For hover and focus, the user must maintain the interaction for this duration before the trigger fires. For click, the trigger fires after this delay. |
| Manual | Evaluates when a developer calls window.webExperiment.toggleManualPageObject('<KEY>', <STATE>), where <KEY> is the name identifier and <STATE> is true to activate the page object or false to deactivate. |
Name identifier that matches the manual trigger key configured in the page settings. |
In a web experiment, you can scope each variant to a specific page to ensure that the variant's changes apply only where you intend. This applies to all variant types.
When you use the Visual Editor to make changes, for example text edits or style updates, those changes associate with the page you select during the preview session. For each change, specify the page or pages it applies to.
This enables you to:
When you add custom code or URL redirects as variants, you can explicitly define which page or pages the variant applies to.
This enables you to create a single experiment that includes custom code with different behaviors, depending on the active page.
Select the page in the the URL redirect variant's settings. Scoping the redirect to a specific page or set of pages ensures that the experiment redirects users only if the the specified page is active.
September 26th, 2025
Need help? Contact Support
Visit Amplitude.com
Have a look at the Amplitude Blog
Learn more at Amplitude Academy
© 2026 Amplitude, Inc. All rights reserved. Amplitude is a registered trademark of Amplitude, Inc.