The Engage Studio — Web Message Previewer Chrome Extension is an authoring assist tool that lets marketers work directly on the live website to:
- Select target elements — Click any element on the page to automatically generate a stable CSS selector (Zone ID) for Inline campaigns.
- Preview campaign content — See how replacement HTML renders on the actual page before going live.
The Chrome Extension is an authoring tool — it is not part of the campaign delivery architecture. Campaigns are delivered to end users via the TD Web SDK, which operates independently of the Extension. Marketers who cannot install the Extension can still create and launch campaigns by entering CSS selectors manually using browser DevTools.
- Google Chrome browser (version 114 or later)
- Access to Engage Studio in your Treasure AI account
- The website you want to target must be accessible in your browser (the Extension works on any HTTP/HTTPS page, including authenticated pages you are already logged into)
The Extension is available on the Chrome Web Store. Search for "Engage Studio — Web Message Previewer" by Treasure AI, or ask your Customer Success Manager for a direct link.
- Open the Engage Studio Extension page on the Chrome Web Store.
- Click Add to Chrome, then confirm by clicking Add extension in the dialog.
- The Engage Studio — Web Message Previewer Extension will appear in your Extensions list with a Treasure AI icon.
Click the puzzle piece icon (Extensions) in the Chrome toolbar and pin the Engage Studio — Web Message Previewer Extension for easy access.
- Navigate to the website page where you want to configure or preview an In-Browser Message.
- Click the Treasure AI icon in the Chrome toolbar.
- A side panel opens on the right side of the browser window.
The Extension cannot run on Chrome system pages (chrome://…), the Chrome Web Store, or browser extension pages. Navigate to a regular HTTP/HTTPS website to use it.
The side panel has two tabs:
- 1 Select — Select a DOM element on the page and edit the replacement HTML.
- 2 Preview — Inject the replacement HTML into the page and compare Original vs. Modified.

Use the Select tab to pick the DOM element you want to replace and generate its CSS selector.
- In the side panel, click Select Element to enter selector mode.
- Move your cursor over the page. The target element is highlighted with a blue border and a tooltip showing the generated CSS selector.
- Click the element you want to target. The side panel populates:
- CSS Selector — the auto-generated selector (e.g.,
div[data-src="drDpRe"] > div:nth-of-type(2) > div). A match count below the field confirms how many elements on the page it targets. - Replacement HTML — an editable field where you enter the HTML content to inject.
- CSS Selector — the auto-generated selector (e.g.,
- Edit the Replacement HTML as needed.
- Use the copy button next to the CSS Selector and Replacement HTML fields to copy each value, then paste them into the In-Browser Message editor in Engage Studio.
To re-pick a different element, click Reselect Element.
To cancel selection without choosing an element, press Escape.
The Extension analyzes the target element and its ancestors to produce a stable CSS selector — one that is less likely to break when the page is updated. The generation strategy prioritizes, in order:
idattribute — if present and not a generated or UUID-like value (for example,#product-banner-area)data-*test attributes — such asdata-testid,data-qa, ordata-cy- Stable
data-*attributes — otherdata-*attributes whose values do not look like hashes or session tokens - Class names — filtered to exclude dynamically generated class names (CSS-in-JS, styled-components, hashed suffixes)
- Structural path — a
tag > tag:nth-of-type(n)path from the nearest stable ancestor
If the page uses a CSS-in-JS library (styled-components, Emotion, CSS Modules), auto-generated class names are filtered out automatically. In these cases, add a stable data-testid or id attribute to the target element for the most reliable selector.
Use the Preview tab to inject the replacement HTML into the live page and verify how it looks before launching.
- Switch to the Preview tab in the side panel.
- When Preview Mode Active is shown (green banner), the replacement HTML has been injected into the page.
- Use the Compare Versions toggle to switch between:
- Original — the page as it normally appears.
- Modified — the page with the replacement HTML injected.
- Review the rendering on the page.
- To remove the injected content, reload the page (
Cmd/Ctrl + R) or navigate away.
The Extension injects content only in your local browser session. No changes are made to the live website or to any campaign settings in Engage Studio. End users are not affected.
| Issue | Solution |
|---|---|
| The side panel shows "This page does not allow extensions" | Navigate to a regular HTTP/HTTPS website. The Extension cannot run on chrome://, chrome-extension://, view-source:, devtools://, or Chrome Web Store pages. |
| Side panel does not open when clicking the icon | Make sure the Extension is enabled at chrome://extensions. Try disabling and re-enabling the Extension, then reload the page. |
| "The previewer has not been loaded on this page. Reload the page (Cmd/Ctrl+R) and try again." error in the side panel | The content script may not have loaded on the current tab. Reload the page (Cmd/Ctrl + R) and reopen the side panel. |
| Element selector highlights nothing | The page may be using Shadow DOM or cross-origin iframes. In these cases, select a wrapping container element outside the shadow root. |
| CSS Selector matches multiple elements (count > 1) | The element lacks a stable id or data-* attribute. Ask a developer to add a data-testid attribute to the target element for a more precise selector. |
| Preview content disappears immediately after injection | A JavaScript framework on the page may be re-rendering the DOM. Try selecting a container element that the framework does not manage, or ask a developer to add a stable insertion point. |
- Only one active side panel is supported per browser window.
- The Extension requires the Side Panel Chrome API (Chrome 114+). Older Chromium-based browsers may not be supported.
- Organizations with restrictive device management (MDM) policies that block Extension installation should use manual CSS selector entry via browser DevTools as an alternative.