Generic OIDC via Cloudflare

Trying to configure Homarr to use generic OIDC via Cloudflare Zero Trust (https://developers.cloudflare.com/cloudflare-one/access-controls/applications/http-apps/saas-apps/generic-oidc-saas/). I have an issue open here (https://github.com/homarr-labs/homarr/issues/4406), but seem to have hit a dead end. I've configured it per the Homarr instructions (https://homarr.dev/docs/advanced/single-sign-on/). I've double checked with other apps I've configured using the same Cloudflare stack and I don't see any obvious configuration issues. I repeatedly get the following error when I try to log in - the name="o" and "name":"t" sometimes change to different letters, but it's always teh same CallbackRouteError and OAUTH_INVALID_RESPONSE.
2025-11-03T16:41:32.701Z error: Read more at https://errors.authjs.dev#callbackrouteerror name="o" type="CallbackRouteError" kind="error"
at dH (/app/apps/nextjs/.next/server/chunks/8673.js:405:19222)
at async dQ (/app/apps/nextjs/.next/server/chunks/8673.js:405:26325)
at async dS (/app/apps/nextjs/.next/server/chunks/8673.js:405:31006)
at async i (/app/apps/nextjs/.next/server/app/api/auth/[...nextauth]/route.js:1:2373)
at async rN.do (/app/node_modules/next/dist/compiled/next-server/app-route.runtime.prod.js:5:21042)
at async rN.handle (/app/node_modules/next/dist/compiled/next-server/app-route.runtime.prod.js:5:25860)
at async k (/app/apps/nextjs/.next/server/app/api/auth/[...nextauth]/route.js:1:7227)
at async rN.handleResponse (/app/node_modules/next/dist/compiled/next-server/app-route.runtime.prod.js:1:105568)
at async g (/app/apps/nextjs/.next/server/app/api/auth/[...nextauth]/route.js:1:8230)
at async x (/app/apps/nextjs/.next/server/app/api/auth/[...nextauth]/route.js:1:9352)
caused by {"err":{"code":"OAUTH_INVALID_RESPONSE","name":"t"},"expected":"[string redacted]","parameters":{},"provider":"oidc"}
2025-11-03T16:41:32.701Z error: Read more at https://errors.authjs.dev#callbackrouteerror name="o" type="CallbackRouteError" kind="error"
at dH (/app/apps/nextjs/.next/server/chunks/8673.js:405:19222)
at async dQ (/app/apps/nextjs/.next/server/chunks/8673.js:405:26325)
at async dS (/app/apps/nextjs/.next/server/chunks/8673.js:405:31006)
at async i (/app/apps/nextjs/.next/server/app/api/auth/[...nextauth]/route.js:1:2373)
at async rN.do (/app/node_modules/next/dist/compiled/next-server/app-route.runtime.prod.js:5:21042)
at async rN.handle (/app/node_modules/next/dist/compiled/next-server/app-route.runtime.prod.js:5:25860)
at async k (/app/apps/nextjs/.next/server/app/api/auth/[...nextauth]/route.js:1:7227)
at async rN.handleResponse (/app/node_modules/next/dist/compiled/next-server/app-route.runtime.prod.js:1:105568)
at async g (/app/apps/nextjs/.next/server/app/api/auth/[...nextauth]/route.js:1:8230)
at async x (/app/apps/nextjs/.next/server/app/api/auth/[...nextauth]/route.js:1:9352)
caused by {"err":{"code":"OAUTH_INVALID_RESPONSE","name":"t"},"expected":"[string redacted]","parameters":{},"provider":"oidc"}
Homarr is deployed as a Docker container on Unraid v1.43.2.
GitHub
homarr-labs/homarr
A modern and easy to use dashboard. 30+ integrations. 10K+ icons built in. Authentication out of the box. No YAML, drag and drop configuration. - homarr-labs/homarr
Solution:
GitHub
bug: OIDC not working with Cloudflare Zero Trust / SaaS · Issue #4...
Describe the bug Attempting to configure Homarr using OIDC via Cloudflare Zero Trust / Generic OIDC. When I set up the variables in https://homarr.dev/docs/advanced/single-sign-on/ I get the follow...
Jump to solution
3 Replies
Cakey Bot
Cakey Bot4w ago
Thank you for submitting a support request. Depending on the volume of requests, our team should get in contact with you shortly.
⚠️ Please include the following details in your post or we may reject your request without further comment: - Log (See https://homarr.dev/docs/community/faq#how-do-i-open-the-console--log) - Operating system (Unraid, TrueNAS, Ubuntu, ...) - Exact Homarr version (eg. 0.15.0, not latest) - Configuration (eg. docker-compose, screenshot or similar. Use ``your-text`` to format) - Other relevant information (eg. your devices, your browser, ...)
Frequently Asked Questions | Homarr documentation
Can I install Homarr on a Raspberry Pi?
Manicraft1001
Manicraft10014w ago
Please do not open multiple requests at the same time Please wait for us to reply on GitHub. I will close this thread
Solution
Manicraft1001
Manicraft10014w ago
GitHub
bug: OIDC not working with Cloudflare Zero Trust / SaaS · Issue #4...
Describe the bug Attempting to configure Homarr using OIDC via Cloudflare Zero Trust / Generic OIDC. When I set up the variables in https://homarr.dev/docs/advanced/single-sign-on/ I get the follow...

Did you find this page helpful?