> ## Documentation Index
> Fetch the complete documentation index at: https://docs.hanko.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Set up SAML SSO with Auth0

> Learn how to set up enterprise connections in Hanko for customers using Auth0 as SAML identity provider.

<div className="hidden">
  **Hanko Auth0 SAML Integration Guide**:

  **About Hanko**:

  Hanko is a modern open source authentication solution and the fastest way you integrate passkeys, 2FA, SSO, and more—with full control over your data. Move between self-hosted and Hanko Cloud anytime. No lock-in. Just Auth how it should be: secure, user friendly, and fully yours.

  **What This Guide Covers**: This guide demonstrates how to configure Auth0 as a SAML identity provider for your Hanko project, enabling secure single sign-on authentication for enterprise users.

  **Key Technologies**:

  * SAML 2.0
  * XML digital signatures
  * Auth0 identity provider
  * SAML assertions

  **Prerequisites**:

  * Active Auth0 account
  * Hanko Cloud project
  * Basic understanding of SAML authentication protocols
  * Admin access to both Auth0 and Hanko Cloud dashboards

  **Tasks You'll Complete**:

  * Set up SAML application in Auth0 dashboard
  * Configure SAML addon with proper ACS URL and settings
  * Set up attribute mapping for email claims
  * Create enterprise connection in Hanko Cloud
  * Test integration using IdP-initiated flow
  * Verify authentication workflow functions properly
</div>

## Prerequisites

You need your project's SAML Assertion Consumer Service (ACS) URL.

### Service Provider ACS URL

To find the Assertion Consumer Service (ACS) URL for your project:

1. Log in to [Hanko Cloud](https://cloud.hanko.io) and select your project.
2. Navigate to `Settings > Enterprise connections`.
3. Under `Enterprise connections` find the `Redirect URL` panel.
4. Copy and save the URL.

<Frame>
  <img src="https://mintcdn.com/hanko/cVK-6eOfdnYqw67X/images/saml/hanko-console-acs-url.png?fit=max&auto=format&n=cVK-6eOfdnYqw67X&q=85&s=e1280846a811aba0f42ce36d9c446051" alt="How to find the Assertion Consumer Service URL in the Hank Cloud enterprise settings of a project" width={500} style={{ borderRadius: "0.5rem" }} data-path="images/saml/hanko-console-acs-url.png" />
</Frame>

## Create an Auth0 application

1. Sign up for an [Auth0 account](https://auth0.com/signup) or [sign in](https://manage.auth0.com/) to access your dashboard.
2. On your dashboard, select `Applications > Applications` in the left sidebar.
3. Click `Create application` to create an application.

<Frame>
  <img src="https://mintcdn.com/hanko/cVK-6eOfdnYqw67X/images/saml/auth0/auth0-create-application.png?fit=max&auto=format&n=cVK-6eOfdnYqw67X&q=85&s=f0256d60282b81d9d4fad4f30814f5ee" alt="Create an Auth0 application from the admin dashboard" width={500} style={{ borderRadius: "0.5rem" }} data-path="images/saml/auth0/auth0-create-application.png" />
</Frame>

4. In the shown modal, enter a name for your application.
5. Select `Regular Web Applications` as the application type.
6. Click `Create` to create the application. You should be redirected to the application's dashboard.

<Frame>
  <img src="https://mintcdn.com/hanko/cVK-6eOfdnYqw67X/images/saml/auth0/auth0-create-application-details.png?fit=max&auto=format&n=cVK-6eOfdnYqw67X&q=85&s=9f168c006968abde9faafade4d4d8a23" alt="Create an Auth0 application from the admin dashboard" width={500} style={{ borderRadius: "0.5rem" }} data-path="images/saml/auth0/auth0-create-application-details.png" />
</Frame>

7. On the application's dashboard, select `Addons` in the top tab navigation.
8. Click on the `SAML2 Web App` panel.

<Frame>
  <img src="https://mintcdn.com/hanko/cVK-6eOfdnYqw67X/images/saml/auth0/auth0-configure-application-saml-addon.png?fit=max&auto=format&n=cVK-6eOfdnYqw67X&q=85&s=fa11ec652e85cd4253e349c210ad2dd9" alt="Create an Auth0 application from the admin dashboard" width={500} style={{ borderRadius: "0.5rem" }} data-path="images/saml/auth0/auth0-configure-application-saml-addon.png" />
</Frame>

9. In the shown modal, select `Settings` in the top tab navigation.
10. In the `Application Callback URL` input provide the ACS URL you obtained as described in
    [Prerequisites - Service Provider ACS URL](#service-provider-acs-url).

<Frame>
  <img src="https://mintcdn.com/hanko/cVK-6eOfdnYqw67X/images/saml/auth0/auth0-configure-application-saml-addon-acs.png?fit=max&auto=format&n=cVK-6eOfdnYqw67X&q=85&s=aa00db19fd3d0fd7b6bf56cdb011f698" alt="Provide Hanko tenant ACS URL in SAML addon settings" width={500} style={{ borderRadius: "0.5rem" }} data-path="images/saml/auth0/auth0-configure-application-saml-addon-acs.png" />
</Frame>

11. Scroll down and select `Enable` to enable the configured SAML addon.

<Frame>
  <img src="https://mintcdn.com/hanko/cVK-6eOfdnYqw67X/images/saml/auth0/auth0-configure-application-saml-addon-enable.png?fit=max&auto=format&n=cVK-6eOfdnYqw67X&q=85&s=196e2ab841c49c73ad0f0628fd8db598" alt="Enable configured SAML addon" width={500} style={{ borderRadius: "0.5rem" }} data-path="images/saml/auth0/auth0-configure-application-saml-addon-enable.png" />
</Frame>

12. Select the `Usage` tab in the top tab navigation.
13. Find `Identity Provider Metadata` and copy the address of `Download` link. You need this for configuring the
    enterprise connection with Hanko in the next section.

<Frame>
  <img src="https://mintcdn.com/hanko/cVK-6eOfdnYqw67X/images/saml/auth0/auth0-configure-application-saml-addon-metadata.png?fit=max&auto=format&n=cVK-6eOfdnYqw67X&q=85&s=577b0116bbf767a3bc2c42c7ec2e6bec" alt="Copy identity provider metadata URL" width={500} style={{ borderRadius: "0.5rem" }} data-path="images/saml/auth0/auth0-configure-application-saml-addon-metadata.png" />
</Frame>

### Attribute mapping

SAML SSO integration with Hanko requires an email address attribute in the IdP's SAML response. The attribute must be available under the name `http://schemas.xmlsoap.org/ws/2005/05/identity/claims/emailaddress`. Auth0 uses this name by default for the `emailaddress` attribute, so no additional configuration is required.

## Configure an enterprise connection

1. Log in to [Hanko Cloud](https://cloud.hanko.io) and select your project.
2. Navigate to `Settings > Enterprise connections`.
3. Under `Connections`, click `New connection`.

<Frame>
  <img src="https://mintcdn.com/hanko/cVK-6eOfdnYqw67X/images/saml/hanko-console-new-saml-connection.png?fit=max&auto=format&n=cVK-6eOfdnYqw67X&q=85&s=73aedc40e30ba0d16a2c930eb38b68f3" alt="Create a new enterprise connection" width={500} style={{ borderRadius: "0.5rem" }} data-path="images/saml/hanko-console-new-saml-connection.png" />
</Frame>

4. In the shown modal provide the following data:
   * A `Name` for the connection.
   * A `Domain` for the connection. When users authenticate via SAML SSO, the domain of the email
     address provided as an identifier at the start of an authentication flow must match the domain configured here.
   * A `Metadata URL`. This is the URL you copied in step 13 in [Create an Auth0 application](#create-an-auth0-application).
   * Select whether you want skip email verification for this provider.
5. Click `Save` to create the connection.

<Frame>
  <img src="https://mintcdn.com/hanko/cVK-6eOfdnYqw67X/images/saml/hanko-console-new-saml-connection-data.png?fit=max&auto=format&n=cVK-6eOfdnYqw67X&q=85&s=eeb6476cb7be828c32d3a7cc5d7f263a" alt="Provide enterprise connection data " width={500} style={{ borderRadius: "0.5rem" }} data-path="images/saml/hanko-console-new-saml-connection-data.png" />
</Frame>

## Testing your integration

To test your integration via [IdP-initiated](/guides/enterprise-sso/introduction#identity-provider-initiated-sso) flow:

1. Navigate to the SAML Addon configuration for your application (see step 8 in [Create an Auth0 application](#create-an-auth0-application)).
2. In the `Usage` tab, find the `Identity Provider Login URL` and click the link.

<Frame>
  <img src="https://mintcdn.com/hanko/cVK-6eOfdnYqw67X/images/saml/auth0/auth0-test-idp-initiated.png?fit=max&auto=format&n=cVK-6eOfdnYqw67X&q=85&s=d97439858fd6bc760a7be32dfd2b07b7" alt="Use the SAML Addons Identity Provider Login URL to test your integration via IdP-initiated login" width={500} style={{ borderRadius: "0.5rem" }} data-path="images/saml/auth0/auth0-test-idp-initiated.png" />
</Frame>
