© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
ImmichI
Immich•9mo ago•
3 replies
HorrayPhobic

Content Security Policy for Immich

Hi, I've recently changed my Immich instance to be accessible from the public internet to allow my friends to use it as well. As I was auditing my setup, I noticed that Immich doesn't provide a Content Security Policy (CSP) header.
A well made CSP can be a major improvement in the webUI's resilience to cross site scripting attacks, especially when unsafe inlining is disabled for both scripts and styles.
Many larger projects like Jellyfin and Mastodon provide a CSP policy out of the box.
In my experience, Nginx, as well as other reverse proxies, pass the CSP header to the client with no configuration, so the project having a CSP would not require any additional actions from those using a reverse proxy.

I've searched through this forum, as well as GitHub, and found a few relatively old posts people who came up with their own CSP for Immich, but neither the upstream project, or the demo instance actually provide a CSP.

Is there any "canonical" source where I could find a CSP for Immich, or does the project not have a CSP yet?

Thank you.

https://developer.mozilla.org/en-US/docs/Web/HTTP/Guides/CSP
MDN Web Docs
Content Security Policy (CSP) - HTTP | MDN
Content Security Policy (CSP) is a feature that helps to prevent or minimize the risk of certain types of security threats. It consists of a series of instructions from a website to a browser, which instruct the browser to place restrictions on the things that the code comprising the site is allowed to do.
Content Security Policy (CSP) - HTTP | MDN
ImmichJoin
A place to hang out, get support, discuss Immich, get announcements about releases and anything else going on.
36,590Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

Immich and Security
ImmichIImmich / help-desk-support
9mo ago
HTTPS for Immich
ImmichIImmich / help-desk-support
5mo ago
hardware setup for immich
ImmichIImmich / help-desk-support
7mo ago
Suggestions for immich Map functions
ImmichIImmich / help-desk-support
3mo ago