Back to docs

Links

Conversion pixel on Wix

Install the Styrar conversion pixel on Wix using Custom Code, with or without Velo.

Option A: Custom Code

  1. In the Wix Editor, go to Settings → Custom Code (sometimes found under Settings → Tracking & Analytics → Custom).

  2. Add a new code snippet:

    • Code: <script src="https://api.styrar.com/v1/pixel/styrar.js" async></script>
    • Add to: Head
    • Apply to: All pages, or just the page your short link points to.
  3. Leave it loading on each new page if you want the pixel available everywhere, not just on first load.

  4. Mark conversions from a button's "on click" code panel:

    JavaScript
    $w('#submitButton').onClick(() => {
      if (typeof window !== 'undefined' && window.styrar) {
        window.styrar.track('signup');
      }
    });
    

Option B: Velo (full code access)

If your site uses Velo (Wix's developer mode), you have regular page code access:

JavaScript
$w.onReady(function () {
  if (typeof window.styrar !== 'undefined') {
    window.styrar.track('purchase', { value: 49.99 });
  }
});

You still need to add the pixel's <script> tag via Custom Code as in Option A — Velo page code runs after the page loads, it can't inject tags into <head>.

Join the beta waitlist

By signing up you agree to receive marketing email. See our Privacy Policy.