Installation guides
Install Muro on Framer
Add the Muro script to a Framer site through the site-wide custom code setting.
Framer has a site-wide custom code setting that runs on every page. Paste the Muro script there and publish.
Steps
Copy your snippet
In Muro, go to Settings → Project → Tracking script and click Copy script:
<script async src="https://api.muroanalytics.com/muro.js" data-project-id="YOUR_PROJECT_ID"></script>Paste it into the head custom code
- Open your project in Framer and open Site Settings.
- In the General section, scroll to Custom Code.
- Paste the snippet into the Start of
<head>tag field. - Save.
Publish
Click Publish. Custom code only runs on the published site, not in the Framer canvas or preview.
Verify it works
- Open your published site (your custom domain or the
framer.websiteaddress). - Open DevTools, go to the Network tab, filter by
collectand reload. You should see aPOSTtocdn.muroanalytics.com/collectwith status202. - Click through to another page. A new
collectrequest appears. - Or, in Muro, set the time picker to Live. Your visit appears within about 30 seconds.
Good to know
- Page changes are tracked. Framer moves between pages without a full reload, using
history.pushState, which Muro listens to. No extra setup needed. - Use site-wide code, not page code. Framer also has per-page custom code. Put Muro in the site-wide setting so it loads once on every page.
- Custom events. Use an Embed or a code component to render a button with a
data-muro-eventattribute, or to callwindow.muro?.track(...). See Track custom events.