How It Works
Installing the Beni chat widget is like adding a Google Analytics snippet to your site. You copy a small piece of code from your dashboard and paste it into your website. That is it. The widget loads on its own, does not slow down your site, and starts working immediately. No developer needed. If you have ever pasted a tracking code or embedded a YouTube video on your site, you can do this.Find Your Embed Code
Log in to your Beni workspace and go to Agents → Select Agent → Chat Widget. You will see a code snippet that looks like this:data-agent-idvalue is already filled- For
data-publishable-key, You need to get publishable key fromSettings → Developers → Publishable Keyspage.
Your publishable key is safe to include on your website. It is not a secret key. It only allows the widget to connect to your specific agent and cannot be used to access your workspace or modify your account. Publishable keys also control which domains are allowed to load your widget — make sure your site’s domain is added under Settings → Developers → Publishable Keys.
Platform Instructions
Pick your website platform below and follow the steps. If your platform is not listed, scroll down to the Custom / Other Platforms section.- WordPress
- Shopify
- Wix
- Squarespace
- Webflow
- Custom / Other
There are a few ways to do this. Pick whichever feels most comfortable.Option A: Using a plugin (easiest)
- In your WordPress dashboard, go to Plugins → Add New
- Search for and install WPCode (or any “header and footer code” plugin)
- Go to Code Snippets → Header & Footer
- Paste your Beni embed code in the Footer section
- Save
- Go to Appearance → Theme File Editor
- Open footer.php from the right sidebar
- Paste your embed code just before the
</body>tag - Click Update File
- Edit the page in the block editor
- Add a Custom HTML block
- Paste your embed code
- Publish
If you are using a block theme like Twenty Twenty-Four, you may not have a footer.php file. Use the plugin method instead.
Google Tag Manager
If you manage all your website scripts through Google Tag Manager, you can add Beni there instead.- In GTM, click Tags → New
- Choose Custom HTML as the tag type
- Paste your Beni embed code
- Set the trigger to All Pages
- Save and Publish the container
For Developers: Single-Page Applications
If your site is built with a JavaScript framework, add the script to your app shell or layout component.- Next.js
- React (Vite / CRA)
- Vue / Nuxt
Verify It Is Working
After adding the code:Open your website
Visit your site in a new browser tab. Use an incognito window if you want to avoid caching issues.
Troubleshooting
Widget is not appearing
Widget is not appearing
Clear your browser cache or open the site in an incognito window. Confirm the snippet is placed before the closing
</body> tag, not inside <head>. Double-check that your data-agent-id and data-publishable-key values have no extra spaces or missing characters. On Wix and Squarespace, verify you are on a plan that supports custom code injection.Widget appears but the agent does not respond
Widget appears but the agent does not respond
Make sure your agent has a published knowledge base in the Beni dashboard. Open your browser console (press F12, then click the Console tab) and check for any error messages. If you see a 401 or 403 error, your publishable key may be incorrect.
Widget overlaps with another chat tool
Widget overlaps with another chat tool
If you have another chat widget installed (Intercom, Drift, Tidio, etc.), it may overlap with Beni. Remove the other widget’s embed code, or adjust the Beni widget position in Agents → Select Agent → Chat Widget.
Widget is blocked on my domain
Widget is blocked on my domain
Publishable keys control which domains are permitted to load your widget. If the widget loads on localhost but not on your live site, go to Settings → Developers → Publishable Keys, select your key, and add your site’s domain to the allowed list. Open the browser console and look for a 403 error if you are unsure whether this is the cause.
Widget looks broken or unstyled
Widget looks broken or unstyled
Some WordPress themes and Shopify themes have aggressive global CSS that can interfere with third-party widgets. If the widget looks off, reach out to us and we will help you sort it out.
Customization
You do not need to touch any code to customize the widget. Everything is managed from your Beni dashboard under Agents → Select Agent → Chat Widget:- Widget color to match your brand
- Chat Widget First Message that greets visitors when they open the chat
- Bubble Text — a short label that appears attached to the widget bubble to invite visitors to click