Skip to main content
Shopify Generic Embed adds Trylora directly to your theme. Trylora prepares the storefront configuration and sends you a personalized installation link containing your public Store Key. You do not need a Trylora dashboard account.

Before you start

You need:
  • A personalized installation link supplied by Trylora
  • Shopify permission to edit theme code
  • The name of the theme you want to update
  • One product URL for verification
  • Access to the GA4 property used by the store

Copy your personalized script

The Store Key selects your Trylora configuration. It is a public identifier, not a password or secret credential. Keep it unchanged so the storefront loads the correct configuration.

Add the script to Shopify

1

Open the theme code editor

In Shopify admin, open Online Store → Themes. Find the theme you want to update, select , and select Edit code.
2

Open the shared layout

Under Layout, open theme.liquid.
3

Paste the script once

Find the closing </body> tag. Paste your personalized Trylora script immediately before it. Ensure that the theme contains only one cdn.trylora.app/embed.js script.
4

Save the theme

Select Save. If you edited an unpublished theme, preview that theme when you verify the installation.

Verify the installation

  1. Open a product page from the updated theme.
  2. If Trylora supplied a private-testing query, add it to the product URL. For example, use ?trylora=1 when the URL has no query string, or &trylora=1 when it already has one.
  3. Confirm that one Try On Button appears in the intended location.
  4. Open Trylora and complete one new try-on.
  5. Send Trylora the tested product URL if the installation needs final review.
A private-testing query works only when Trylora has enabled the matching Page Targeting Rule for your store. The script alone does not create that rule.

Connect Google Analytics

Follow Connect your Shopify GA4 property to create the two values Trylora needs to send try-on events to your existing GA4 property:
  • The web stream’s Measurement ID
  • A Measurement Protocol API secret from the same web stream
The guide also explains the separate property ID and Analyst-access steps used when Trylora prepares reports.

Troubleshooting

The button does not appear

  • Confirm that you edited the theme you are viewing.
  • Confirm that the personalized Store Key was not changed.
  • Confirm that the script appears once before </body> in the rendered page.
  • Confirm that the page URL includes the private-testing query when your store requires one.
  • Send Trylora the exact product URL so the Store URL, targeting rules, and placement can be checked.

Trylora appears twice

  • Remove duplicate Generic Embed scripts.
  • Remove any duplicate script injected by a tag manager or another theme snippet.

A security policy blocks Trylora

The script must load from https://cdn.trylora.app. Review browser Content Security Policy errors and allow the Trylora origins and resource types reported for the installation.