Tested tool guide
Tested browser tools
Checked August 16, 2026
What SRI Hash Generator does, with a checked example
This tool turns file contents into the Subresource Integrity (SRI) hash that goes inside a script or link tag's integrity attribute, so the browser can reject anything a CDN has tampered with. It digests the exact bytes you enter and returns the ready-to-use value with the algorithm prefix, in the form sha384-.... The thing that surprises most people: the hash must be of the file exactly as served, byte for byte. Hash your local source file instead of the minified build the CDN actually serves, and every visitor's browser will block the resource.
Worked example
A concrete input and expected output from the current implementation.
->
Expected output
sha384-ywB1P0WjXou1oD1pmsZQBycsMqsO3tFjGotgWkP/W+2AhgcroefMI1i67KE0yCWh
Hashing the three ASCII bytes of 'abc' with SHA-384 and base64-encoding the 48-byte digest yields that 64-character string; the sha384- prefix is the algorithm label the integrity attribute requires. For a real deployment, paste the file's exact served contents - change one byte and the whole digest changes.