Tools / Subresource Integrity checker
Subresource Integrity (SRI) checker
Enter a URL. We list every external script and stylesheet the page loads and flag the cross-origin ones that carry no integrity hash — the gap a compromised CDN or third-party host would walk straight through.
More free checks
Run a full security scan or speed test on your site, or try a related tool.
Related free tools
What SRI is
Subresource Integrity lets you pin a cryptographic hash of a script or stylesheet in the tag that loads it:
<script src="https://cdn.example.com/app.js"
integrity="sha384-oqVuAfXRKap7fdgcCY5uykM6+R9GqQ8K/uxy9rx7HNQlGYl1kPzQho1wx4JwY8wC"
crossorigin="anonymous"></script>
The browser downloads the file, hashes the bytes it received, and refuses to run them if the hash does not match. If the CDN is compromised and serves altered JavaScript, the hash no longer matches and the browser blocks it. Without SRI, whoever controls that host controls code running on your origin — with full access to your DOM, your cookies and your users.
How to read the result
- Cross-origin, no integrity (flagged ⇗) — the real exposure. A script or stylesheet from a different registrable domain runs with no verification. A supply-chain compromise of that host executes on your page.
- integrity present, crossorigin missing — a subtle trap. For a cross-origin resource the browser needs
crossorigin="anonymous"to read the response and verify the hash; without it the integrity attribute is silently ignored. It looks protected and is not. - Same-origin, no integrity — lower risk, because an attacker who can alter a file on your own origin has already breached you. Still worth hashing build artifacts to catch a tampered deploy.
The pattern this catches most often
A team hardens the obvious third-party tags — the analytics snippet, the font loader — and misses one: a widget, a charting library, an A/B-testing script pulled from a vendor CDN that pushes updates on its own schedule. That is exactly the kind of host that gets compromised, and exactly the tag most likely to lack an integrity attribute because “it updates itself.” A self-updating third-party script and SRI are in direct tension: SRI pins a specific version, so you have to pin to a versioned URL rather than a floating “latest.” That friction is the whole reason the gap exists.
Limits
Hashes are read from the HTML; this tool does not re-download each resource to confirm the hash still matches its current bytes (a mismatch would show up as a blocked resource in the browser console). It sees only scripts and styles in the initial HTML, not ones injected later by JavaScript. SRI also does not apply to images or to a stylesheet’s own @imported children.
Related checks: the CSP evaluator — a strong script-src and SRI are complementary controls — the security headers analyzer for the rest of the response, and the secret & API key scanner for what those bundles might be leaking.
Frequently asked questions
How do I generate an SRI hash?
Hash the exact file you serve with SHA-384 and Base64-encode the result. The hash generator produces the ready-made integrity value from a file in your browser. Many CDNs also publish the value next to each file.
Do scripts from my own domain need SRI?
It is optional. SRI protects against a third-party host serving altered files. For files served from your own origin, an attacker who can change them can usually change your HTML too.
Why did my site break after the CDN updated a library?
The integrity hash matches one exact file. Loading a “latest” URL with SRI fails as soon as the file changes. Always pin an exact version in the URL when you use integrity.
Which hash algorithm should I use?
SHA-384 is the common choice and is what most CDNs publish. SHA-256 and SHA-512 are also accepted by every modern browser.