Back to Installing Your Chatbot

How to add a ChatGPT AI support agent to any HTML website

You want to embed your custom trained AI support agent to your HTML website. Here's how to add an AI support agent to any HTML website with SiteSpeakAI.

Add your AI support agent to your HTML website website

In SiteSpeakAI

1. Copy the SiteSpeakAI JavaScript code snippet

Log into your SiteSpeakAI account and select your agent from the dropdown menu at the top, click on the Install Agent section in the sidebar, select the Javascript tab and then click on the Copy Code button to copy your agent code snippet.

uploads/help-center/images/AvSb6iF2OUXlQnC1hnpDeC1bpplkn7AzQ6pTFZmt.png

In your website

1. Adding the code

Using a simple editor (Notepad (Windows), TextEdit (Mac), or a code editor like VS Code) add the code snippet to your the website HTML code in the <head> or <body> section of your HTML file.

<!-- SiteSpeakAI - Add ChatGPT to your website -->

<script type="text/javascript">(function()	{d=document;s=d.createElement("script");s.src="https://sitespeak.ai/chatbots/########-####-####-####-############.js";s.async=1;d.getElementsByTagName("head")[0].appendChild(s);})();</script>

<!-- / SiteSpeakAI -->

2. Important Notes

  • Caching: Browsers often cache (save) files. If you make changes and they don't appear, clear your browser's cache (usually in your browser settings).
  • Code Editors: Using a code editor like VS Code will make writing and managing your code much easier. They provide syntax highlighting, error checking, and other helpful features.
Need more help with SiteSpeakAI?

Not finding what you need? Reach out to our support team for help.

Contact Support

Ready to automate your customer service with AI?

Join over 1000+ businesses, websites and startups automating their customer service and other tasks with a custom trained AI agent.