Muro
Installing Muro

Install Muro on WordPress

Add Muro to a WordPress site using a plugin like WPCode, or by editing your theme's header.php directly.

There are two common ways to add a tracking script to a WordPress site. Pick whichever fits how you already manage your site.

Option 1: WPCode (or similar plugin)

This is the safest option for most users. You don't touch theme files, and the snippet survives theme updates.

  1. From the WordPress admin, go to Plugins → Add New.

  2. Search for WPCode, install it, and activate it.

  3. Open Code Snippets → + Add Snippet.

  4. Choose Add Your Custom Code (New Snippet) and pick HTML Snippet as the code type.

  5. Paste:

    <script async src="https://api.muroanalytics.com/muro.js" data-project-id="YOUR_PROJECT_ID"></script>
  6. Set Location to Site Wide Header (which inserts the code into <head> on every page).

  7. Toggle the snippet to Active and click Save Snippet.

The script is now on every page of your site.

Other plugins that work the same way: Insert Headers and Footers, Header Footer Code Manager, Code Snippets. Pick whichever you already use.

Option 2: Edit header.php directly

If you're comfortable editing theme files, you can paste the snippet into your theme's header.php.

  1. From the WordPress admin, go to Appearance → Theme File Editor.

  2. Open header.php.

  3. Find the closing </head> tag and paste the snippet just before it:

    <script async src="https://api.muroanalytics.com/muro.js" data-project-id="YOUR_PROJECT_ID"></script>
    </head>
  4. Click Update File.

Use a child theme

Editing header.php on a parent theme means your snippet gets wiped on the next theme update. If you go this route, use a child theme.

Where to find your project ID

Open your Muro dashboard, go to Settings → Project → Tracking script, and click Copy script. The project ID is the value of data-project-id.

Verify

  1. Open the front of your site in a browser.
  2. In Muro, set the time range to Live.
  3. Reload your site in another tab.
  4. Your visit appears within 30 seconds.

If you see nothing, view source on the site and confirm the snippet is actually in the <head>. WordPress caching plugins can sometimes serve a stale copy. Clear your cache (for example in WP Rocket, LiteSpeed, or W3 Total Cache) if that's the case.

What's next

On this page