https://retellai.com/?utm_source=discord&utm_medium=seo logo
How to deploy a chat agent to a website
# ❓・ai-evy-support
d
@AI Evy How to deploy a chat agent to a website?
a
Thanks for tagging me @dzei2234. I'll look through relevant sources and get back to you shortly.
### Answer To deploy a chat agent to your website, use the Retell embeddable website widget [(1) ]() . The widget is embeddable via a single
<script>
tag and uses the Retell public key system, allowing direct API calls from the frontend—no backend proxy required . Prerequisites: - Create a chat agent using the Create Chat Agent guide - Get your Retell Public Key - Get your chat agent ID Setup: Add this script tag to your HTML within the
<head>
tag :
Copy code
html
<script
 id="retell-widget"
 src="<https://dashboard.retellai.com/retell-widget.js%22>
 type="module"
 data-public-key="YOUR_RETELL_PUBLIC_KEY"
 data-agent-id="YOUR_CHAT_AGENT_ID"
 data-agent-version="YOUR_AGENT_VERSION"
 data-title="YOUR_CUSTOM_TITLE"
 data-logo-url="YOUR_LOGO_URL"
 data-color="YOUR_CUSTOM_COLOR"
 data-bot-name="YOUR_BOT_NAME"
 data-popup-message="YOUR_POPUP_MESSAGE"
 data-show-ai-popup="true"
 data-show-ai-popup-time="5"
 data-auto-open="false"
 data-dynamic='{"key": "value"}'
 data-recaptcha-key="YOUR_GOOGLE_RECAPTCHA_SITE_KEY"
></script>
Required attributes: -
data-public-key
- Your Retell public key -
data-agent-id
- Your chat agent ID The widget displays a robot icon in the bottom right corner . When clicked, it opens a chat interface in a modal window . Chat sessions are automatically handled and persisted in localStorage .
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
​ To learn more, see the sources I considered: [[1] Retell Website Widget](https://docs.retellai.com/deploy/chat-widget) ​