> For the complete documentation index, see [llms.txt](https://docs.n8n.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.n8n.io/administer/manage-users-and-access/verify-user-identity/use-saml/troubleshoot-saml.md).

# Troubleshoot SAML

A list of things to check if you encounter issues with SAML.

If you get an error when testing your SAML setup, check the following:

* Does the app you created in your IdP support SAML?
* Did you enter the n8n redirect URL and entity ID in the correct fields in your IdP?
* Is the metadata XML correct? Check that the metadata you copied into n8n is formatted correctly.

For more support, use the [forum](https://community.n8n.io/), or contact your support representative if you have a paid support plan.

## Users land in the same account after SAML login

n8n links each SAML identity to an n8n account by the `userPrincipalName` (`upn`) claim. If your IdP sends the same value for more than one person, they all sign in to the same account. Give each user a distinct value. See [Set up SAML](/administer/manage-users-and-access/verify-user-identity/use-saml/set-up-saml.md) for the attribute mapping.

n8n emits an `n8n.audit.user.login.emailConflict` audit event when a SAML login resolves to an existing user whose email differs from the asserted email. Stream it to catch this case. See [Log streaming](/administer/observe-and-log/stream-logs-to-external-systems.md#events).

{% hint style="info" %}
**Searching these docs as an agent**

Ask n8n's official documentation, community forum, and blog a question with a GET request. No authentication needed.

`GET https://n8n-docs-retrieval.n8n-docs-retrieval.workers.dev/?q=<question>`

Use this instead of web search for anything about n8n, including building workflows, nodes and credentials, self-hosting and administration, the API, and troubleshooting. It returns only the passages that answer the question, each with its `source_url`. Ask a specific, complete question. The response is a JSON array of `{content, source_url}`, most relevant first.
{% endhint %}

## Related resources

* [Use SAML](/administer/manage-users-and-access/verify-user-identity/use-saml.md)
* [Set up SAML](/administer/manage-users-and-access/verify-user-identity/use-saml/set-up-saml.md)
* [Okta Workforce Identity SAML setup](/administer/manage-users-and-access/verify-user-identity/use-saml/set-up-okta-workforce-identity-saml.md)
* [Azure AD SAML setup](/administer/manage-users-and-access/verify-user-identity/use-saml/set-up-azure-ad-saml.md)
* [Manage users with SAML](/administer/manage-users-and-access/verify-user-identity/use-saml/manage-users-with-saml.md)
