How to add a chatbot to your website
Updated 2026-08-19
You can add a chatbot to your website in about fifteen minutes, on any platform, without a developer. Every modern chat widget installs the same way: a single line of code pasted into your site's HTML. This guide walks through the whole path — what to prepare, where the snippet goes on each major platform, and how to test before your visitors see it.
Before you install: three things to prepare
- The content it will answer from. Your website URL plus any documents customers ask about — price lists, policies, FAQs. An assistant grounded on real content answers usefully from day one.
- Where questions should land. Decide the email (or phone) that receives handoffs when a conversation needs a human.
- Its look. A name, a colour that matches your site, and a short greeting. Small details, but they decide whether the widget feels like part of your business.
The snippet
Whatever product you choose, installation is one <script> tag. With ChatbotPilot it looks like this — one line, loaded asynchronously, so it never slows your page:
<script src="https://chatbotpilot.io/w.js?id=your-assistant"></script>
Paste it just before the closing </body> tag, or in your platform's designated code box, and the chat bubble appears on every page.
Platform by platform
WordPress
Appearance → Theme File Editor is the old way; the safe way is a header/footer code plugin or your theme's "custom scripts" box. Full detail, including Elementor and Divi notes, in our WordPress chatbot guide.
Shopify
Online Store → Themes → Edit code → theme.liquid, paste before </body>. Ecommerce assistants can do more than answer questions — see AI chatbots for ecommerce for order lookups and product Q&A.
Wix
Settings → Custom Code → Add Custom Code, paste the snippet, apply to All Pages, load "Body — end".
Squarespace
Settings → Advanced → Code Injection → Footer, paste, save. Available on Business plans and above.
Test before you announce
- Ask it the five questions customers ask you most. Check the answers against your actual policies.
- Ask something it cannot know. The right behaviour is admitting it and offering your contact details, not improvising.
- Open the site on your phone. The widget should not cover buttons or block checkout.
The fifteen-minute path
If you would rather skip the building entirely: ChatbotPilot builds the assistant from your website and documents after a short questionnaire — you paste the snippet and it is answering the same day, in your brand, with conversations visible in your dashboard. New to the whole topic? Start with the small business chatbot guide, or get started here.