Troubleshooting the widgets

The script loaded and nothing appeared. The usual causes, in the order worth checking them.

6 min read Last updated

On this page

Widgets fail quietly. The script loads, finds its containers, and then — if it has nothing to show — shows nothing: a star badge, gallery, carousel or FAQ list with no data renders no markup at all rather than an empty box. That keeps an unreviewed product from displaying a hollow frame, and it also means a widget with no data looks exactly like a widget that is broken.

Open your browser’s developer console first. Almost every cause below announces itself there, and the SDK prefixes its own messages with [Evident].

Start here

What you seeMost likely cause
Nothing renders; the console shows blocked requests or a Content Security Policy violationContent Security Policy
Nothing renders; the console shows CORS errorsOrigin not allow-listed
An [Evident] message saying a widget requires an attributeMissing attribute
Works in production, not on a preview deployOrigin not allow-listed
Review list says “Failed to load reviews”, or star badges are blankProduct not found
Review list says “No reviews yet” when you know there are someNo approved reviews
Renders on first load, disappears after navigationRoute changes
Review form works, then starts failingRate limits
Widgets work but ignore your colours and fontsTheme not applied
Reward values show as bare numbersCurrency not set

Content Security Policy

Symptom. The widget never appears. The console reports a request or resource blocked by your Content Security Policy, usually naming api.evidentugc.com.

Cause. The SDK loads from app.evidentugc.com but fetches all of its data from api.evidentugc.com. A policy that allows the script but not the connection produces a widget that loads perfectly and has nothing to display.

Fix. Add connect-src https://api.evidentugc.com — it is the source most often missing. The complete list, including what video reviews and photo uploads need, is under Headless storefronts → Content Security Policy. It applies to every storefront that enforces a policy, not only headless ones.

Test before you enforce. Ship the policy as Content-Security-Policy-Report-Only first. A report-only policy logs violations without blocking anything, so you find out what you are about to break before your customers do.

Origin not allow-listed

Symptom. CORS errors in the console. The widget works on one site and not another — production but not staging, or staging but not a preview build.

Cause. Evident authorises storefront requests by the page’s origin. A browser on an origin that is not on the list gets a response without the header that lets it read the data, and refuses it.

Fix. Settings → Store → Allowed Storefront Origins. Add every origin you render from:

https://yourstore.com
https://staging.yourstore.com
http://localhost:3000

Changes take effect immediately — reload the page to test.

Three things that catch people:

  • Preview deployments are separate origins. Every Vercel and Netlify preview URL is its own origin and stays blocked until listed. If your team ships a preview per pull request, a stable preview alias saves you chasing generated URLs.
  • There are no wildcards. * and pattern syntax are rejected when you save.
  • An origin is scheme, host and port. No paths, no trailing slash, and a bare domain is treated as https. The www. and bare forms of a domain count as one, but any other subdomain — shop.yourstore.com — needs its own entry.

Do not debug this with curl. It sends no Origin header, so the request succeeds and tells you nothing. Reproduce in a browser. This one wastes more time than anything else on this page.

Missing attribute

Symptom. The console shows [Evident] Widget "star-badge" requires data-product-id attribute, or the equivalent for a gallery (data-gallery-slug) or the loyalty panel (data-email). A misspelled widget type gives [Evident] Unknown widget type.

Fix. Check the container against Installing the widgets. When the value comes from a template variable, check what the template actually rendered — an empty data-product-id="" counts as missing.

Product widgets show nothing

Symptom. Galleries, FAQs and the store carousel render. Star badges stay blank, and per-product review lists show “Failed to load reviews” or “No reviews yet”.

Cause. Product-scoped widgets need the product in Evident, under exactly the ID the widget asks for. Store-wide widgets do not.

Work through it in this order:

  1. Is the product in Evident? A connected BigCommerce or Shopify store syncs its catalogue automatically. A headless store pushes it with PUT /api/v1/products — see Headless storefronts. There is no catalogue screen in the admin app, so on a headless store check with GET /api/v1/products.

  2. Does the ID match exactly? The value your widget passes as data-product-id must be the same string you sent as platformProductId:

    <div data-evident-widget="star-badge" data-product-id="sku-1024"></div>

    …matches a product pushed as "platformProductId": "sku-1024". The comparison is exact: "sku-1024", "SKU-1024" and "sku-1024 " are three different products. A product Evident does not know about is what produces “Failed to load reviews”, and the review form says so outright: “This product is not yet in the Evident catalog.”

  3. Are any of its reviews approved? Widgets show only approved reviews. A product whose reviews are all pending shows a blank star badge and “No reviews yet” in the list. Check Reviews → All Reviews, filtered to pending.

Orders exist but no review requests go out

Symptom. The catalogue is right, orders are arriving, and nobody is being asked for a review.

Cause. Several conditions all have to hold, and each one fails silently. Check, in order:

  1. Are review request emails switched on? They are off for a new store. Settings → Store → Review Settings → Configure → Enable review request emails.
  2. Has the delay elapsed? Requests are scheduled, not immediate — 14 days after the order by default, set in the same dialog. An order pushed this morning will not produce an email today.
  3. Are orders reaching Evident? Orders in the left navigation.
  4. Are the line items linked? An order whose products are missing is stored but inert. The PUT /orders response reports unlinkedLineItems across the store; push products first.
  5. Is the status one that counts? Requests trigger on Shipped by default. An integration sending Processing looks broken when it is only ineligible.
  6. On a headless store, did you set scheduleReviewRequests? Pushing an order never schedules a request without it, and orders dated more than 30 days ago are skipped even with it.

Review request emails covers the whole flow, including products you have excluded on purpose.

Widget disappears after a route change

Symptom. Renders on first load. Vanishes after client-side navigation, or after your framework re-renders the page.

Cause. Usually none — the SDK watches the page and mounts containers your framework adds later, re-mounting them if a re-render wipes the node. It renders into a wrapper element it owns rather than into your node directly, specifically so a React or Vue re-render cannot blank it.

Fix. If it still happens, mount explicitly from your component’s lifecycle with window.Evident?.mount(el) and window.Evident?.unmount(el), or call window.Evident?.refresh() after each navigation to re-scan the page. Headless storefronts has React and Vue examples.

Review submissions start failing

Symptom. The review form works, then returns 429 — usually during testing.

Cause. Storefront writes have much tighter limits than the rest of the API, because they are unauthenticated and come from shoppers. Review creation allows 3 a second and 5 a minute, counted per visitor IP address. That is generous for real shoppers and very tight for someone submitting test reviews in a loop — if you see it in development, you are almost certainly the cause.

Fix. Wait a minute, or test from a different network. In production, handle 429 in the form with a human message rather than a generic error. The limits for every storefront action are listed under Using the API → Storefront write limits.

Theme not applied

Symptom. The widgets work, but in their default look — the colours and fonts set under Storefront → Install & Theme do not show.

Cause. The SDK writes your theme settings into a <style> element on the page, and a Content Security Policy without 'unsafe-inline' in style-src blocks it. The console reports the blocked style.

Fix. Add 'unsafe-inline' to style-src, or accept the default styling.

Prices and rewards show without a currency symbol

Symptom. Reward values, store credit and points-per-amount-spent render as bare numbers.

Cause. The store’s currency is not set. Settings → Store → Currency reads “Not set — amounts are shown without a currency symbol.” until it is. On a BigCommerce or Shopify store it is read from the platform; on a headless store you choose it there.

Fix. Set it before launching loyalty. It is used everywhere Evident shows an amount to a shopper — see Setting up loyalty.

Still stuck

Open the console and check, in this order: blocked resources (Content Security Policy), CORS errors (origins), [Evident] messages (attributes), then the network tab for a 4xx from api.evidentugc.com. A 403 whose code is plan_required or subscription_expired is a billing gate rather than a bug — see Billing & plans.

If none of that explains it, email [email protected] with the page URL, the widget type, and what the console says.

Something missing or out of date? Email [email protected] — docs corrections go straight to the team that builds the feature.