Add Tidio to your Bolt website by asking Bolt to place the widget script in your app's shared document or layout. Bolt supports frontend JavaScript frameworks and Node.js backends, so the prompt below does not assume a specific stack.
In this article, you'll learn:
- How to find your Public key
- How to ask Bolt to add the widget
- How to add the script yourself
- How to give Bolt the Tidio documentation
- How to check the installation
- How to troubleshoot the widget
Find your Public key
Log in to your Tidio panel and go to Settings > Developer > Project data. Click the Public key field to select its value, then copy it.
The Public key is part of the script address that every visitor's browser loads, so you can keep it in front-end code. The private key on the same page is different: never put it in your website.
You'll find the same key inside the installation code in Settings > Live Chat > Installation, under Manual install:
<script src="//code.tidio.co/YOUR_PUBLIC_KEY.js" async></script>
Ask Bolt to add the widget
Open your existing project and paste this request into the Bolt chat. Replace YOUR_PUBLIC_KEY before sending it.
Add the Tidio live chat widget to this project.
1. Load this script once on every page, at the end of the body, with async:
<script src="//code.tidio.co/YOUR_PUBLIC_KEY.js" async></script>
2. Put it in the root HTML document or the root layout, so it loads once and stays loaded during client-side navigation. Do not add it to single pages or to a component that mounts more than once.
3. Do not install an npm package for Tidio. The script tag is the whole installation.
4. Do not use window.tidioChatApi on the server. Use it only in the browser, after the "tidioChat-ready" event fires on document.
5. Change nothing else, then tell me which file you edited.
Reference: https://help.tidio.com/articles/install-ai-coding-agents/
Review the file Bolt names. The installation needs one script, not a separate copy for every page.
If you know your stack, use the guide for Next.js, React, React Router and Remix, TanStack Start, Vue, Nuxt, SvelteKit, Astro, Angular, Gatsby, SolidStart, Qwik, or Eleventy.
Add the script yourself
Use Code view on a desktop Chromium-based browser, such as Chrome. Bolt's Code view is read-only in Safari.
- Click the code icon at the top center of the project.
- In Files, open your root HTML document or the framework's shared layout.
- For a plain HTML document, put the script below just before
</body>. For a framework layout, follow the matching framework guide above. - Click Save.
<script src="https://code.tidio.co/YOUR_PUBLIC_KEY.js" async></script>
Choose either the prompt or manual approach. Do not add a second script after Bolt has installed it.
Give Bolt the Tidio documentation
Bolt supports custom MCP connectors. Connect Tidio's read-only documentation server so Bolt can search articles and read installation instructions.
- From the Bolt homepage chatbox, click the plus icon, then Connectors and Manage connectors.
- Choose Custom MCP server and name it Tidio documentation.
- Set URL to
https://help.tidio.com/mcp, Transport type to HTTP, and Authentication to None. Tidio's documentation server needs no login. - Click Connect. In your project chatbox, open the plus menu, choose Connectors, and turn on the Tidio connector.
Ask Bolt to use search_articles to find the installation guide for your framework and get_article to read it before editing.
To keep the installation constraints in future prompts, click the project name, then All project settings and Knowledge. Append this instruction in Project instructions and click Save prompt:
Keep one Tidio script in the root document or layout. Do not install a Tidio npm package. Consult the Tidio documentation MCP server before changing the widget integration.
See Bolt's MCP connector guide for connection settings.
Check the installation
Open your site in a regular browser window. The chat widget appears in the corner of the page and stays there when you move between pages. Headless and automated browsers may not show the widget, so do not rely on them for this check.
Loading a page with the widget is what activates it. After that, Settings > Live Chat > Installation in your Tidio panel says Chat Widget is installed properly.
In Bolt, click Publish at the top right, then Publish again. Open the published link for the widget check. For an already published site, choose Update in the Publish menu to release your changes.
Troubleshooting
- If the widget does not load, check that you replaced
YOUR_PUBLIC_KEYwith the Public key from your Tidio project. - If you see two widgets or duplicate script requests, remove the extra installation. Keep one loader in the root document or layout.
- If server rendering reports that
windowordocumentis not defined, move that code into the framework's browser-only lifecycle. - If your Content Security Policy blocks the widget, allow
code.tidio.coinscript-srcand follow the full Tidio CSP host list. - If an automated check cannot see the widget, repeat the check in a regular browser window on the published site.
