How to add Supadesk to Replit
Replit hosts web apps and static sites from a Repl workspace. This guide shows you how to add the Supadesk AI chat widget to Replit by pasting the embed script into your main HTML file, so the widget loads on your deployed site instead of only in the in-editor preview.
Before you start
- In Supadesk, open your agent and click Chat Widget.
- Click Copy Embed Code.
- (Recommended) Add your deployed Replit URL to Allowed Origins — use your production domain, not the temporary
.repl.codev URL.
Install on Replit
- Open your Repl project.
- In the file sidebar, open
index.html(or your app’s main HTML entry file). - Find the closing
</body>tag. - Paste your Supadesk embed script on the line immediately above
</body>. - Save the file.
- Deploy your Repl ( Deploy or Publishing tab, depending on your Repl type).
Replit tip
Use your deployed production URL in Allowed Origins, not the ephemeral .repl.co preview link. Dev preview URLs change and may block the widget.
Check it works
Open your deployed Replit URL in a private browser window. The chat bubble should appear in the bottom-right corner.
Troubleshooting
- Widget missing: Confirm you deployed after saving
index.html. The in-Repl preview alone may not match production. - Widget blocked: Add your exact deployed origin (including
https://) to Allowed Origins in Supadesk.
FAQ
Where do I paste Supadesk in Replit?
Paste the Supadesk embed script in index.html or your app’s main HTML entry file immediately before the closing </body> tag. Then deploy the Repl.
Which Replit URL should I add to Allowed Origins?
Add the deployed production URL, including https://. Temporary preview URLs can change, so they should not be the only origin allowed for the Supadesk widget.
Does Supadesk work in the Replit editor preview?
It may, but the editor preview is not the source of truth. Test Supadesk on the deployed Replit URL because that is the origin your visitors and Allowed Origins setting depend on.
More install guides
Don't have a Supadesk account?
Start free, create your agent, then come back to this guide to install the widget on your site.
Start free