Skip to main content

Before You Start: Whitelist Your Website

You must whitelist your domain before the widget will load. In the Lua AI admin dashboard, go to Chat WidgetCustomization and add your website URL to the allowed sites list. The widget silently refuses to initialise on any domain not listed here.
Testing on localhost? localhost cannot be whitelisted — the dashboard approach will not work. You must pass your configuration inline and set environment: "production" explicitly:
This bypasses the domain whitelist check so you can develop and test locally against your real agent.

Setup Options

There are two ways to get the widget running. The dashboard approach is recommended — it requires no code changes when you update settings.

Common Setups

Customer Support

Sales Assistant

Embedded Chat (No Floating Button)

Quick Customizations

Change Position

Custom Colors & Button

Testing Environments

Staging (For Testing)

Production (Live)

Always test with environment: "staging" before switching to production!

Framework Integration Quick Start

React

Vue

More Framework Examples

See integration guides for Angular, Next.js, and more

Troubleshooting

Check these:
  1. Open browser console for JavaScript errors
  2. Verify your agent ID is correct
  3. Ensure script is loaded after DOM is ready
  4. Check if another chat widget is conflicting
Solutions:
  1. Check your internet connection
  2. Verify agent ID exists in Lua AI dashboard
  3. Try environment: "staging" for testing
  4. Check browser console for API errors
Solutions:
  1. Check for CSS conflicts using browser dev tools
  2. Try a different position
  3. Add higher z-index:

Next Steps

Full Configuration

Explore all configuration options

Custom Styling

Match your brand perfectly

Real Examples

See production implementations

Track Events

Monitor chat interactions