Help centre
العربية Back to sayvara.com

Website widget

Ask visitors of your website for feedback with a small prompt, choose the pages, visitors and moments, and limit how often anyone is asked.

Updated

Add-on, available on request.

The website widget is a small prompt on your own website. When a page and a visitor match your rules, it asks "Got a minute? Tell us how we did." Selecting Start opens one of your surveys in a new tab. Answers land in Responses like answers from any other channel.

Everyone who can see responses can open the Website widget page. Owners, admins and managers add, change, pause and remove widgets.

How it works

  1. You add a widget, choose the survey and list the https addresses of your website.
  2. You paste one script tag on your site.
  3. On each page, the script reads your rules and decides in the visitor's own browser whether to ask.
  4. When the widget decides to ask, Sayvara first gives a fresh survey link that works for 30 minutes; the prompt then appears and Start opens it. So each prompt shown counts as one survey link, whether or not the visitor selects Start.

The widget asks at most once per page view. If a visitor's browser blocks site storage, the widget cannot keep its limits, so it never asks that visitor.

Add a widget

  1. Go to Website widget in the side menu and select Add widget.
  2. Under Widget:
    • Name: for your team only, for example "Shop: after checkout".
    • Survey: the survey the prompt opens.
    • Language when the page does not say: Arabic or English.
    • Website addresses: one https address per line, for example https://shop.example.com. Up to 10. https://*.example.com covers every subdomain. The widget answers only on these addresses.
    • Survey links per day: from 1 to 100,000 (5,000 at first). Above it the prompt stays hidden until the next day, Riyadh time.
  3. Set the rules in the sections below, then select Add widget.

Paste the script tag

Each widget card shows its Script tag. Select Copy and paste it once on every page of the site, just before </body>. It looks like this:

<script async src="…/v1/w.js" data-sayvara-key="wk_…"></script>
  • The wk_ key is public. It is not a secret.
  • Optional: data-lang="ar" or data-lang="en" sets the prompt's language. Without it, the widget follows the page's <html lang>, and then the widget's own language.
  • Optional: data-theme="light" or data-theme="dark". Without it, the prompt follows the visitor's setting.
  • If the tag is on a page twice, only the first one works.

If the card shows a note instead of a script tag, this Sayvara service does not serve the widget script. Your widgets and rules stay saved.

Content Security Policy

If your site sets a Content Security Policy, add:

Directive Allow
script-src the script's address, from the tag you copied
connect-src https://api.sayvara.com

When the human check is on (see Human check), also allow the human-check address in script-src and frame-src. The tag card in Settings > Website widget shows it. Your browser's console names any address that the policy blocks.

Pages

  • Ask only on these pages: one path per line, for example /checkout/*. A star matches anything. Empty means every page.
  • Never ask on these pages: these win over the list above.

Up to 20 paths in each list. Paths start with /. The query (?…) and the # part are not matched, and a slash at the end is ignored.

Who may be asked

Setting What it does
Share of visitors (%) From 1 to 100. Each visitor is picked once, so the same people keep their place.
Device Every device, Phones and tablets or Computers. A narrow window or a touch screen up to tablet size counts as a phone or tablet.
Visitor Every visitor, First page viewed only or From the second page viewed. The widget counts page views, not visits: the second page of a first visit already counts as the second page viewed.
Pages viewed first Pages this widget has counted for the visitor in this browser, this one included. Each widget counts its own pages, and only on pages where it runs. 0 means no minimum. With First page viewed only, use 0 or 1: Sayvara refuses a higher number, as it would never ask.
Page languages Language codes such as ar, en, up to 10. The widget reads data-lang, then <html lang> (ar-SA counts as ar). Empty means any language.
Page address parameters Ask only when the page address has these parameters, for example utm_source = newsletter. * means any value. Up to 10.
Names your site may call See Ask after a task.

About page address parameters:

  • The list offers common names first: utm_source, utm_medium, utm_campaign, utm_term, utm_content, ref, source, campaign and variant.
  • Values are compared exactly, upper and lower case included.
  • The check happens in the visitor's browser. The values are never sent to Sayvara.
  • Names that often carry private data are refused, for example names with token, email, phone or session, and names such as id, user, name or code.

On a single-page site, a change of route counts as a new page view: the widget checks the rules again and starts the triggers again.

When it asks

Trigger What it does
After some time on the page Seconds on the page, from 0 to 600 (15 at first).
When the pointer leaves the window The pointer leaves through the top of the window. Computers only.
After the visitor scrolls Scrolled (%), from 10 to 100.

Turn all three off to ask only when your site calls Sayvara.show().

Ask after a task

Your site can ask at the right moment, for example after an order or a closed ticket:

Sayvara.show();                 // ask now, if the rules allow
Sayvara.show('order_placed');   // ask with a name
Sayvara.hide();                 // remove the prompt

Under Names your site may call, list up to 10 names (letters, digits and _ . : -). When the list is empty, any call to Sayvara.show() may ask. When it has names, only a call with a listed name asks.

Sayvara.show() still follows the pages, the audience and the limits.

How often

Setting Default Range
Prompts at most in In days 2 in 30 days 1 to 20 prompts, 1 to 365 days
Days of quiet after the survey is opened 90 0 to 730
Days of quiet after "Not now" 14 0 to 365

Select Share one limit across all widgets on the same address to cap the prompts from every widget on one site address together: Prompts at most, from any widget (1 to 50) in In days (1 to 365).

Good to know:

  • The limits are kept in each visitor's own browser, for each site address. shop.example.com and help.example.com count apart.
  • A different browser or device counts as a new visitor. Clearing the browser's data starts the limits again.
  • Survey links per day is a separate cap for the whole widget, counted by Sayvara: one link for each prompt shown.

The prompt

  • Corner: the end corner (right in English, left in Arabic) or the start corner.
  • Prompt in English and Prompt in Arabic: up to 120 characters each. Empty uses "Got a minute? Tell us how we did."
  • The survey always opens in a new tab.

Human check

When this Sayvara service has the human check (Turnstile) switched on, the widget solves it before it gets a survey link. Most visitors see nothing. If the check needs a click, a small box shows in the bottom corner. If the check fails, the prompt stays hidden.

Pause, change or remove

  • Pause stops new prompts within a minute. Resume starts them again.
  • Edit changes any setting. Visitors' browsers pick up the change within about a minute.
  • Remove stops the widget for good. This cannot be undone.

Survey links already given out keep working for up to 30 minutes.

Each card also shows Survey links today and Survey links in total: one link for each prompt shown, whether or not the visitor selected Start.

Privacy

  • The widget keeps its counts in your site's own browser storage. It sets no cookie and keeps nothing about the visitor on Sayvara's side.
  • When it asks for a survey link, it sends the page path (no query, no # part) and the prompt's language. Query parameter values never leave the visitor's browser.