Integrations
Add QuerySafe to Any Website
One line of code. Works on WordPress, Shopify, Wix, Squarespace, React, or plain HTML.
codeYour Embed Code
After training your chatbot, you will get a unique embed code from your dashboard. It looks like this:
<script src="https://console.querysafe.ai/widget/YOUR_BOT_ID/querySafe.js"></script>
Replace YOUR_BOT_ID with your actual chatbot ID from the dashboard.
WordPress
- Log in to your WordPress admin panel.
- Go to Appearance > Theme File Editor (or use a plugin like "Insert Headers and Footers").
- Open the
footer.phpfile (or the "Footer Scripts" section in the plugin). - Paste your embed code just before the closing
</body>tag. - Click Update File (or Save in the plugin).
- Visit your site and verify the chat widget appears in the bottom-right corner.
lightbulb
Tip: If you use a page builder (Elementor, Divi), you can also add the script via the theme's Custom Code or a Custom HTML widget in the footer area.
Shopify
- From your Shopify admin, go to Online Store > Themes.
- Click Actions > Edit code on your active theme.
- In the Layout folder, open
theme.liquid. - Scroll to the bottom and find the
</body>tag. - Paste your embed code just before
</body>. - Click Save and preview your store.
lightbulb
Tip: The widget works on all pages including product pages, cart, and checkout (if allowed by your theme).
Wix
- Go to your Wix dashboard and open your site editor.
- Click Settings (gear icon) in the left menu.
- Select Custom Code under the Advanced section.
- Click + Add Custom Code.
- Paste your embed code, name it "QuerySafe Chatbot".
- Set placement to Body - end and apply to All pages.
- Click Apply and publish your site.
Squarespace
- In your Squarespace dashboard, go to Settings > Advanced > Code Injection.
- Paste your embed code in the Footer section.
- Click Save.
- The widget will appear on all pages of your site.
React / Next.js
Add the script using a useEffect hook in your root component or layout:
useEffect(() => {
const script = document.createElement('script');
script.src = 'https://console.querysafe.ai/widget/YOUR_BOT_ID/querySafe.js';
script.async = true;
document.body.appendChild(script);
return () => document.body.removeChild(script);
}, []);
const script = document.createElement('script');
script.src = 'https://console.querysafe.ai/widget/YOUR_BOT_ID/querySafe.js';
script.async = true;
document.body.appendChild(script);
return () => document.body.removeChild(script);
}, []);
Plain HTML
- Open your HTML file in any code editor.
- Paste the embed code just before the closing
</body>tag. - Save the file and open it in your browser.
<!DOCTYPE html>
<html>
<head>...</head>
<body>
<!-- Your content -->
<script src="https://console.querysafe.ai/widget/YOUR_BOT_ID/querySafe.js"></script>
</body>
</html>
<html>
<head>...</head>
<body>
<!-- Your content -->
<script src="https://console.querysafe.ai/widget/YOUR_BOT_ID/querySafe.js"></script>
</body>
</html>
FAQ
Integration Questions
Common questions about adding QuerySafe to your site
Copy the embed script from your QuerySafe dashboard and paste it before the closing </body> tag on your website. It works on any platform — WordPress, Shopify, Wix, Squarespace, React, or plain HTML. One line of code, no plugins required.
No. The script loads asynchronously, so it does not block your page from rendering. The widget itself is lightweight and only activates when a visitor clicks on it.
Yes. Place the embed code in your site's global footer or layout template, and the chatbot will appear on every page. You do not need separate codes for different pages.
Yes. You can add the script tag to your index.html or load it inside a useEffect hook in your root component. The widget handles route changes automatically.
Ready to Add AI Chat to Your Website?
Create your chatbot, train it, and embed it in under 5 minutes.
Get Started Free