Install via browser snippet
Paste the async snippet into your <head> and the SDK loads automatically. No build step, no npm — works on plain HTML, WordPress, Shopify themes, Webflow, and any static site.
Looking for the React / Next.js / bundler install? See Quickstart. Letting an AI agent (Claude Code / Cursor) do the install? See Install with AI.
What you’ll need
- Your API key from the dashboard at Settings → API Keys (format
st_live_...orst_test_...). - Access to your site’s HTML head (theme editor / page template / file editor).
The snippet (recommended)
Copy this into your site’s <head> — anywhere before </head> is fine, but earlier is better (more autocaptured pageview/click events captured before users navigate away):
<script>
!function(){
if(window.TrackCrumb)return;
var q=[];
var st={
_q:q,
init:function(){q.push(['init',arguments])},
track:function(){q.push(['track',arguments])},
identify:function(){q.push(['identify',arguments])},
reset:function(){q.push(['reset',arguments])}
};
window.TrackCrumb=st;
var s=document.createElement('script');
s.async=true;
s.src='https://docs.iwanttotrysomething.site/sdk/v1/sdk.min.js';
document.head.appendChild(s);
}();
TrackCrumb.init({
apiKey: 'st_live_REPLACE_ME',
apiHost: 'https://ingest.iwanttotrysomething.site'
});
</script>Replace st_live_REPLACE_ME with your real API key. That’s it — autocapture (pageviews + clicks + form submits) starts immediately. Manual events:
<script>
TrackCrumb.track('signup_completed', { plan: 'growth' });
TrackCrumb.identify('user_42', { email: '[email protected]' });
</script>You can call TrackCrumb.track(...) before the SDK has finished loading — calls are queued and replayed automatically.
Pinned version (production)
The snippet above uses /sdk/v1/sdk.min.js — the latest 0.x release. Patches roll out automatically. For stricter change control, pin to the exact version with a Subresource Integrity (SRI) hash:
<script>
/* same async stub as above, except: */
s.src = 'https://docs.iwanttotrysomething.site/sdk/<EXACT-VERSION>/sdk.min.js';
s.integrity = '<EXACT-SRI-HASH>';
s.crossOrigin = 'anonymous';
</script>For SDK 0.3.0:
| Value | |
|---|---|
| URL | https://docs.iwanttotrysomething.site/sdk/0.3.0/sdk.min.js |
| Integrity | sha384-4qGJuFY/JoUQP6/vSLtljVJWCH7H+g/Qedeqe9xIPoQmaCpKQaukiCf+4t+Lp+9T |
Bumping the SDK requires updating both the URL and the hash in your snippet. The latest values are always at https://docs.iwanttotrysomething.site/sdk/0.3.0/sdk.min.js.sri.
Verify
- Open your site in an incognito window with DevTools → Network.
- Confirm
sdk.min.jsloads with status 200 fromdocs.iwanttotrysomething.site. - Open DevTools → Console:
window.TrackCrumbshould be an object withinit,track,identify,reset, andTrackCrumbproperties. - Open the dashboard → Live Events stream → events should appear within seconds.
Platform-specific tips
WordPress
We ship a first-class WordPress plugin that handles snippet install + WP user identification + WooCommerce auto-capture. Use that instead of the manual snippet for any WP site.
Shopify (custom theme)
Open Online Store → Themes → Edit code → theme.liquid. Paste the snippet just above </head>. Save.
Webflow
Project Settings → Custom Code → Head Code. Paste the snippet. Save and publish.
Squarespace / Wix
Both expose a “Custom HTML in head” setting. Paste the snippet, save.
Plain static HTML
Paste the snippet directly into the <head> of every page (or your shared header partial / template).
Strict CSP
If your site uses a Content Security Policy, you’ll need:
script-srcto allow'self','unsafe-inline'(for the bootstrap stub) OR anonce/hashcovering the inline script, plushttps://docs.iwanttotrysomething.site.connect-srcto allowhttps://ingest.iwanttotrysomething.site.
What gets captured automatically
Out of the box, autocapture records:
$pageviewon every navigation / load.$clickon any element clicked, with the full element chain (tag, classes, text, data-attributes, CSS path).$form_submiton form submits.
These events stream to ClickHouse and surface in the dashboard’s Trends, Funnels, and Retention views with no further wiring.
Compatibility
- All modern evergreen browsers: Chrome, Firefox, Safari, Edge (last 2 major releases).
- Brotli + gzip pre-compressed bundles are served when supported (47 KB / 70 KB respectively).
- IE11 and below: not supported.
Next steps
- Identify your users so events tie to a specific person — see Quickstart §4.
- Track custom events — see Quickstart §5.
- Set up funnels and retention — see the User Manual.
- Privacy + cookie consent — the snippet starts capturing on load. If your jurisdiction requires consent, gate the snippet behind your consent plugin (CookieYes, Complianz, OneTrust). The SDK does not auto-detect consent state.