Troubleshooting SSO
Diagnose and resolve common issues with SSO authentication, group sync, and user provisioning.
Retool reports most SSO failures by redirecting back to the login page with the reason in the URL, as /auth/login?error=<message>. If you're testing the connection from the SSO settings page rather than signing in, the same message appears at /settings/sso-test?error=<message> instead. Either way, read that URL message first: it names the specific check that failed, and the sections below are organized around those messages.
Why can't anyone log in after I enabled SSO?
Two settings remove the email and password fallback. Turning either on before SSO actually works locks out every user, administrators included.
- Disable Login with Email and Password removes the email and password form entirely.
- Trigger Login Automatically redirects users into the SSO flow as soon as they reach your instance, so they never reach the form even while it's still enabled.
- Cloud instances
- Self-hosted instances
Both settings live on the Single Sign On (SSO) settings page. If you can still reach the login form as an administrator, turn them off there.
If no one can reach the form at all, contact Retool support. Retool can restore the password login path for your organization.
Environment variables override whatever the SSO settings page shows, so check them first. Any of these disables or bypasses the email and password form:
| Variable | Effect |
|---|---|
DISABLE_USER_PASS_LOGIN | Removes the email and password form. |
RESTRICTED_DOMAIN | Also removes the email and password form, in addition to restricting SSO to the listed domains. |
TRIGGER_SAML_LOGIN_AUTOMATICALLY | Redirects straight into the SAML flow. |
TRIGGER_OAUTH_2_SSO_LOGIN_AUTOMATICALLY | Redirects straight into the OIDC flow. |
Unset the ones you don't need, then apply the change the way your deployment applies configuration: retool_helm_extra_values in main.tf plus terraform apply for Terraform blueprints, values.yaml plus helm upgrade for Helm, or docker.env plus sudo docker compose up -d for Docker Compose. Refer to the environment variables reference, which covers all three.
If the environment variables are already clear and users still can't reach the form, the settings were saved from the SSO settings page instead. Contact Retool support for help restoring the password login path.
To avoid this entirely, confirm users can complete a full SSO login (not just a successful test connection) before enforcing it. Refer to Enforce SSO for the full sequence.
Why do I get "The email must be specified as a SAML attribute"?
Retool identifies users by email address and requires it as an attribute on every SAML assertion. Your identity provider is either omitting the attribute or sending it under a different name.
Configure your identity provider to send the user's email address in an attribute named email. Refer to your provider's tutorial for the exact field:
Why do I get "SAML response Destination does not match the configured ACS URL"?
The Destination attribute in the SAML response doesn't match the Assertion Consumer Service URL Retool expects. This almost always means the identity provider was configured against a different hostname than the one users actually reach.
Check these in order:
- The ACS URL registered with your identity provider matches your Retool instance's hostname exactly, including protocol and any port.
- If you use a custom domain, the identity provider points at the custom domain rather than the default one.
- Your load balancer or reverse proxy forwards the original host header. A proxy that rewrites the host makes Retool build an ACS URL that no longer matches the one the identity provider was given.
Why do I get "Authentication request expired or could not be verified"?
Retool binds each SAML response to the authentication request that started it, and rejects responses it can't match to an outstanding request.
Common causes:
- The user started the login in one browser tab and finished it in another after the original request expired. Ask them to start again from the login page.
- Cookies are blocked or stripped between Retool and the browser. Retool stores the outstanding request in a cookie, so a proxy or browser setting that drops it breaks the binding.
- The user initiated the flow from a bookmarked identity provider URL. Service provider initiated login must start at Retool.
A closely related message, SAML response has already been used. Please re-authenticate to obtain a new response., means the same assertion was submitted twice. Retool consumes each assertion once, so have the user start a fresh login rather than refreshing or resubmitting.
Why do I get "Authentication failed" with a parser error?
Retool couldn't parse or validate the SAML response, and appends the underlying reason to the message. Certificate mismatch and clock skew are the most common causes.
- Confirm the certificate configured in Retool is the current signing certificate from your identity provider. Certificates rotate, and an expired or superseded one fails validation.
- Confirm the system clocks on both sides are synchronized. SAML assertions carry a narrow validity window, and a few minutes of drift invalidates them.
- Confirm the identity provider signs the assertion, the response, or both, in whatever combination Retool is configured to expect.