Use this option if you have access to your website’s HTML template (or a tag manager) and want to install the CutMeShort Analytics script directly.Documentation Index
Fetch the complete documentation index at: https://docs.cutmeshort.com/llms.txt
Use this file to discover all available pages before exploring further.
Add the script to your site
Paste the script once on every page of your website, ideally inside the<head> tag so it can read the landing-page URL before the user navigates.
Where to place it
- Static HTML sites: put it in the shared layout file right before
</head>. - Single-page apps (React/Vue/Next, etc.): put it in your app’s document/layout head so it loads on all routes.
- Tag managers: create a Custom HTML tag that fires on All Pages.
What the script does
Once installed, the script:- Reads attribution from the landing URL: detects
cms_rfin the query string (example:?cms_rf=abc123). - Stores attribution as a first-party cookie: saves the value for the configured cookie duration (for example, 30 or 90 days), so conversions that happen later can still be attributed.
- Exposes a global tracking object: makes the client SDK available under
window._cmsfor debugging/verification. - Sends events with attribution attached: when your lead/sale events are fired, the stored
cms_rfis included so the conversion is credited to the original CutMeShort link click.
Configuration options
You can pass the following attributes on the script tag:data-config
| Type | JSON string |
| Example | {"days":30,"attribution":"last"} |
days) and attribution model (attribution) for tracking.
Use one of these script configurations:
Verification
- Open your website, then open the browser console and run:
window._cms
- Visit a test landing page URL that includes
cms_rf, for example:https://your-site.com/?cms_rf=test
- Confirm a first‑party cookie is set (in your browser devtools under Application → Cookies).
- The script is present in the
<head>and not duplicated. - Your site (or CDN) is not serving a cached version of the page missing the script.
