Paperless-ngx SSO with Authentik (OIDC)

Connect an authentik provider to Paperless-ngx through django-allauth.

Last updated

On this page (5)

Paperless-ngx · Authentik · OIDC

Before you start

  • Paperless-ngx 2.5.0 or later and access to docker-compose.env or paperless.conf.
  • authentik admin access.

Configure sign-in

  1. Create an authentik application with an OAuth2/OpenID Connect provider and a signing key. Register https://<paperless>/accounts/oidc/authentik/login/callback/ as the strict authorization redirect URI.
  2. Enable allauth.socialaccount.providers.openid_connect in PAPERLESS_APPS. Set PAPERLESS_SOCIALACCOUNT_PROVIDERS with openid_connect.OAUTH_PKCE_ENABLED true and an APPS entry with provider_id authentik, its ID and secret, and settings.server_url https://<authentik>/application/o/<slug>/.well-known/openid-configuration.
  3. Restart Paperless-ngx, then link existing users via My Profile > Connect new social account. Decide separately whether to allow signup or redirect the login page.

Verify the result

  • Verify a linked user can sign out and back in through authentik without a duplicate account.
  • Retain a working local administrator login during testing.

Official documentation

Have Pilae connect your identity provider

Pilae can deploy Paperless-ngx with your identity provider already connected. We agree the edition, account mapping and access tests with your team before rollout.