Widget installation
Add this script right before </body>:
<script
src="https://widget.setchat.co/setchat.iife.js"
data-api-key="site_xxx"
data-api-url="https://api.setchat.co"
defer
></script> - React/Vite: put it in
index.html. - Astro: place in global layout.
- WordPress: official plugin or footer snippet.
Installation checklist
- Create a dedicated SetChat site (one API key per site/domain).
- Install the script on a staging environment first.
- Validate widget open/close behavior on desktop and mobile.
- Confirm message send/receive in real conditions.
- Roll out to production after validation.
Multi-site setup and best practices
- Use a different API key per website/domain.
- Do not reuse one key for staging and production.
- Version your integration snippets with frontend changes.
- Document key ownership and where each key is deployed.
Quick troubleshooting
- Widget not visible: verify script loading in network/console.
- API error: check
data-api-urland site API key. - No conversations: test in private browsing without ad blockers.
- Inconsistent behavior: clear cache/CDN and reload script.