https://retellai.com/?utm_source=discord&utm_medium=seo logo
Hello, How to get the embed code for my AI agent i...
# ❓・ai-evy-support
k
@AI Evy Hello, How to get the embed code for my AI agent in Retell ai? to integrate with my web
a
Thanks for tagging me @kavindya_k. I'll look through relevant sources and get back to you shortly.
### Answer Yes, you can embed your Retell AI agent on your website using the Retell Website Widget [(1) ]() . The widget supports both Chat Widget and Callback Widget modes . To get the embed code for your AI agent, you need to add a 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"}'
></script>
Before embedding the widget, you'll need : 1. **Create an Agent**: For chat widget, create a chat agent using the Create Chat Agent guide 2. **Get Your Credentials**: Your Retell Public Key and your Retell agent ID 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 . You can copy and paste the embed script into your website, replace the publicKey, agentId, and version, and customize the widget name [(2) ]() .
​ To learn more, see the sources I considered: [[1] Retell Website Widget](https://docs.retellai.com/deploy/chat-widget) [[2] Chat Widget, Custom Function Enhancement and more!](https://www.retellai.com/changelog/chat-widget-custom-function-enhancement-and-more) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
k
is there a way to get my own AI Agent's Retell embed snippet (script/iframe)? @User