Multi-platform Integrations
Add Chatbots to WordPress Websites
Add your AI agent to every page of your WordPress site with the free Chat Data plugin. No coding needed.
Before you start
- A trained AI agent. New here? Create an account, then train your agent with your data.
- Admin access to your WordPress dashboard.
With the plugin you don't copy any code. You paste only your Chatbot ID (step 2).
Step 1: Allowlist your WordPress domain
In Chat Data, open Settings > Security. Set Visibility to public, turn on Embedding On Websites, and add your WordPress domain to Allowed Embedding Domains. To hide the AI agent on certain pages of your site, list them in Disallowed Urls. Full details: Allowlist your domain. 
Step 2: Install the Chat Data plugin (recommended)
- In WordPress, go to Plugins > Add New and search for
Chat Data. You can also download it from the WordPress Plugin Directory. - Install and activate the plugin.

- In Chat Data, open your AI agent's Settings > General and copy the Chatbot ID (under Chatbot Info).
- In WordPress, go to Settings > Chat Data Options and paste it into Chatbot ID.
- Leave Embedding Domain as
www.chat-data.com. Change it only if you are on our reseller plan and host the script on your own domain; see White Label Your Chatbot. - Click Save Changes.

The plugin adds the chat bubble to every page of your site.
Alternative: edit your theme's functions.php file
Use this only if you are comfortable editing theme files. It is more direct, but a mistake in functions.php can break your site.
- Go to Appearance > Theme Editor, select your current theme and open
functions.php. You can also edit the file over FTP in your theme's folder. - Add this code at the end of the file. Replace the
<script>line with the Widget Bubble code you copied from Embed on site in Chat Data.
function add_custom_script_to_head() {
echo '<script src="https://www.chat-data.com/embed.min.js?chatbotId=YOUR_CHATBOT_ID" defer></script>' . "\n";
}
add_action('wp_head', 'add_custom_script_to_head');

Check that it worked
Open your live WordPress site. The chat bubble should appear. If the chat window shows "Domain: … is not in the allowlisted domains of this chatbot", add that domain in Step 1. More fixes: Check that it worked.
Next step: match the bubble to your brand in Settings > Chat Interface. See Customize the Chatbot Interface.
Frequently Asked Questions
How do I add a Chat Data chatbot to a WordPress website?
The WordPress process starts by allowlisting your production domain in Chat Data and setting the chatbot to `public`, then adding the chatbot to the site either with the official Chat Data plugin or by adding the embedding script to the theme's `functions.php` file.
Why do I need to allowlist my WordPress domain first?
The guide explains that the main WordPress domain must be allowlisted so the chatbot is permitted to appear on the production website. It also notes that you can disallow specific URL paths if there are pages where you do not want the chatbot to show.
What is the recommended way to install the chatbot on WordPress?
The recommended approach is to use the official Chat Data WordPress plugin, available at https://wordpress.org/plugins/chat-data/. You can also search for `Chat Data` under Plugins > Add New in your WordPress dashboard, install and activate the plugin, then go to `Settings` > `Chat Data Options` and paste your Chatbot ID, which you copy from `Settings` > `General` in your Chat Data chatbot.
Can I install the chatbot on WordPress without the plugin?
Yes. You can also use a manual method where you edit the theme's `functions.php` file and hook a script into `wp_head`. It is a more direct and permanent method, but it requires careful theme-file editing.