Skip to main content
All integrations

Add Zovibot to React (Vite or CRA)

About 2 min

For a single-page app the script belongs in the HTML shell, not in a component. Putting it in a component means it re-runs on every mount.

Steps

The snippet below is a placeholder — yours carries your own site key.
  1. Edit index.html

    Vite keeps this at the project root; Create React App keeps it in public/. Paste before </body>.

    Copy this
    <script async src="https://zovibot.leadfella.com/zovibot.js" data-site-key="pk_live_YOUR_SITE_KEY"></script>
  2. Rebuild and deploy

    The tag is part of the built HTML, so it survives client-side routing automatically.

Worth knowing

  • If you must load it from a component, guard against double-inserting the tag on re-render — check for an existing script with the same src first.