Sparklines Not Working With Inline Script Error

I have GD installed.

When viewing my Matomo dashboards none of the sparklines appear. If I look at console errors I see the following error:

injectlaunchmonitors.js:131 Refused to execute inline script because it violates the following Content Security Policy directive: “script-src ‘self’ ‘wasm-unsafe-eval’ ‘inline-speculation-rules’ chrome-extension://c03a3860-159d-42c9-87a9-ad87043ce506/”. Either the ‘unsafe-inline’ keyword, a hash (‘sha256-+osnfquB23g9K0xV1ls9W1PGJx2yRDNBiM+W8Bj/zdc=’), or a nonce (‘nonce-…’) is required to enable inline execution.

Any ideas on how to fix this so I can start seeing sparklines?

1 Like

This error happens because your browser or an extension (like an ad blocker or security add-on) is enforcing a Content Security Policy (CSP) that blocks Matomo’s inline scripts.

To fix it:

  1. Disable or whitelist any Chrome extensions (especially security or privacy ones) for your Matomo site.

  2. If you manage the server, update the CSP header to allow Matomo’s inline scripts using a nonce or hash.

  3. Try viewing in Incognito mode or another browser to confirm it’s a CSP issue.

Once the inline script is allowed, the sparklines should appear normally.