v149 · CSS · Security

Live Playground

Build any combination of CSS url() request modifiers and instantly see the generated CSS snippet. Tweak the resource URL, pick a CORS mode, add an SRI hash, and set a referrer policy — the output updates live. Use the HTML parity panel to compare with the equivalent HTML attribute syntax.

Modifier controls
Generated CSS
/* configure modifiers on the left */
HTML attribute equivalent
Fetch request effect
// Fetch options derived from modifiers
CSS url() modifier reference
Modifier
Values
Effect on fetch
cross-origin()
anonymous, use-credentials
Sets CORS mode on the request; anonymous omits credentials, use-credentials includes cookies/certs
integrity()
sha256-…, sha384-…, sha512-…
Applies SRI check to the response; browser rejects the resource if the hash doesn't match
referrer-policy()
no-referrer, strict-origin, …
Controls what URL is sent in the Referer header when requesting the resource

see also