Back to Installation

Wix Installation Guide

Step-by-step guide to install TwoBucks Analytics on Wix.

Quick Start

Method 1: Custom Code (Recommended)

  1. Go to Settings → Custom Code
  2. Click + Add Custom Code
  3. Configure:
    • Name: TwoBucks Analytics
    • Code Type: Head
    • Paste your code:
<script
  src="https://twobucks.ai/script.js"
  data-website-id="your-website-id"
  async
></script>
  1. Select Load code on: All pages
  2. Click Apply

Track Wix Events

Button Clicks

  1. Select your button
  2. Go to Settings → Interactions
  3. Add On ClickRun Custom Code:
if (window.twobucks) {
  window.twobucks('button_click', {
    button_text: 'Sign Up',
    page: window.location.pathname
  });
}

Form Submissions

  1. Select your form
  2. Go to Settings → Form Settings
  3. Add After SubmitRun Custom Code:
if (window.twobucks) {
  window.twobucks('form_submit', {
    form_name: 'Contact Form',
    page: window.location.pathname
  });
}

Common Issues

Script Not Loading

  1. Ensure script is in Settings → Custom Code → Head
  2. Check Load code on is set to All pages
  3. Verify data-website-id is correct

Custom Code Not Running

  1. Ensure code is added to the correct element/event
  2. Check browser console for errors
  3. Verify script loads before custom code runs

Wix ADI Sites

If using Wix ADI (Artificial Design Intelligence):

  1. Switch to Editor mode
  2. Follow the Custom Code method above
  3. ADI sites may have limited custom code support

Next Steps