LEDIAN

Website Web Widget

Add an AI-powered chat widget to your website in minutes.

1. Copy the snippet

Open your Business Dashboard, go to Web Widgets, then copy the embed snippet from the integration section.

2. Embed it on your site

Paste the snippet right before </body>. If needed, you can also place it in the <head>.

<script src="https://api.ledian.io/widget.js" data-wid="WID_..." data-sid="SID_..." defer></script>

Use the exact WID and SID from your own dashboard for production.

3. Test the widget

Reload your website, open the widget, and send a test message. Confirm that widget.js and API requests load successfully.

If it does not load

Check CSP, browser extensions, and cache/CDN state.

script-src https://api.ledian.io
connect-src https://api.ledian.io

Platform guides

WordPress
  1. Open wp-admin and go to Appearance → Theme File Editor.
  2. Open footer.php.
  3. Paste the snippet right before </body>.
  4. Save, clear cache, and reload the live page.
Shopify
  1. Open Online Store → Themes → Edit code.
  2. Open layout/theme.liquid.
  3. Paste the snippet before </body>.
  4. Save and test in preview and live mode.
Webflow
  1. Open Project Settings → Custom Code.
  2. Paste the snippet into Footer Code.
  3. Publish the project.
  4. Hard-refresh the published page and test.
Wix
  1. Open Settings → Custom Code.
  2. Add a new custom script in the footer.
  3. Select all relevant pages.
  4. Publish and verify on the live site.
Squarespace
  1. Open Settings → Advanced → Code Injection.
  2. Paste the snippet in Footer.
  3. Save and publish.
  4. Refresh and test the widget.
Next.js
  1. Add the snippet in app/layout.tsx or pages/_document.tsx.
  2. Deploy the change.
  3. Open production and verify widget.js loads.
React
  1. Paste the snippet in public/index.html before </body>.
  2. Build and deploy the app.
  3. Verify widget.js and API calls in DevTools.
Other
  1. Find your global template/footer file.
  2. Paste the snippet right before </body>.
  3. Deploy changes.
  4. Check CSP, cache, and blockers if it does not load.

Support: support@ledian.io