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

# Single Sign-On

> Let members sign in through your SAML identity provider, with domain verification and JIT provisioning.

StackOne Single Sign-On (SSO) lets your organization members sign in through your own SAML 2.0 identity provider (IdP). Once you connect an IdP and verify your email domain, any member whose work email is on that domain is sent to the IdP to authenticate instead of using a StackOne password.

Set this up in **Organization > Security > SSO** in the StackOne dashboard. You need the **Org Admin** role.

<Note>
  The **SSO** tab is enabled per organization. If you don't see it under **Organization > Security**, even as an Org Admin, contact StackOne support to turn it on.
</Note>

## How SSO works

* StackOne acts as the SAML service provider (SP), and your IdP holds and authenticates the identities.
* Each organization has one SSO connection, bound to one email domain.
* Members with an email on your verified domain are redirected to your IdP when they sign in.

## Before you begin

Have these ready:

* The **Org Admin** role in your StackOne organization.
* Admin access to your SAML 2.0 IdP, such as Okta or Microsoft Entra ID.
* The ability to add a DNS TXT record for your email domain, which StackOne uses to verify ownership.

## Set up an SSO connection

On the **SSO** tab, select **Get started** to open the setup wizard. It opens in a side panel titled **Set up SSO** and collects your IdP's details in a few steps.

<Steps>
  <Step title="Which identity provider are you using?">
    Select **Okta**, **Microsoft Entra ID**, or **Other SAML 2.0 provider**. Your choice tailors the field labels to match your IdP's console.
  </Step>

  <Step title="Connection details">
    Enter a **Connection name** like `Acme Okta`, and the **Domain** your members' email addresses use, such as `acme.com`. Members with an email on this domain sign in through SSO.
  </Step>

  <Step title="Configure your identity provider">
    StackOne shows an **ACS URL**, an **SP Entity ID**, and a **Default RelayState**. Copy them into your IdP's SAML application so it knows where to send assertions, how to identify StackOne, and where members land after an IdP-initiated sign-in.
  </Step>

  <Step title="Register your SSO provider">
    Copy your IdP's **Entity ID (Issuer)**, **SSO URL (Entry Point)**, and **X.509 Certificate** back into StackOne. To fill all three at once, select **Upload SAML metadata file** and import the metadata your IdP generates.
  </Step>

  <Step title="Verify your domain">
    Add the DNS TXT record StackOne generates to your domain, then verify it. Verification is what activates the connection.
  </Step>
</Steps>

Once registered, the connection is listed on the **SSO** tab with its **Connection**, **Domain**, and **Status** (Verified or Unverified). Select the connection to open its settings, where you can edit the SAML configuration, edit the domain, and verify it.

<Frame>
  <img src="https://mintcdn.com/stackone-60/y1H5HYQCzx5b5iEx/images/identity/sso/sso-connections-table.png?fit=max&auto=format&n=y1H5HYQCzx5b5iEx&q=85&s=05b533b01a859f3ef592e1b690573d5c" alt="The SSO tab listing each connection with its Connection name, Domain, and Status (Verified or Unverified)." width="1568" height="229" data-path="images/identity/sso/sso-connections-table.png" />
</Frame>

The exact clicks differ per IdP. Follow the guide for yours: [Okta](/identity/sso/okta), [Microsoft Entra ID](/identity/sso/microsoft-entra), or [any SAML 2.0 provider](/identity/sso/saml-generic).

## Verify your domain

Domain verification proves your organization owns the email domain on the connection. You add a TXT record that StackOne generates to your domain's DNS, and StackOne checks for it. Until the domain is verified, the connection is registered but inactive.

Verifying the domain unlocks three things:

* **SSO sign-in.** Members with an email on the domain are redirected to your IdP to authenticate.
* **Account linking.** An existing StackOne user whose email is on the domain is linked to the SSO connection, so they keep one account instead of a duplicate.
* **Trusted directory emails.** Emails provisioned through Directory Sync are treated as verified, so SSO can link those users when they first sign in.

## How members sign in

When a member signs in, they enter their email address on the StackOne sign-in page. If the email is on a verified SSO domain, StackOne redirects them to your IdP. After the IdP authenticates them, they return to StackOne signed in.

<Tip>
  IdP-initiated sign-in also works. A member who opens the StackOne tile from your IdP lands on the StackOne dashboard already signed in. They still need organization membership from an invitation or Directory Sync. IdP-initiated sign-in authenticates them but doesn't place them in your organization.
</Tip>

## Just-in-time provisioning

The first time someone signs in through SSO without an existing StackOne account, StackOne creates their account automatically. This is just-in-time (JIT) provisioning, so you don't pre-create an account for every member.

With JIT enabled, that first sign-in also adds the person to your organization: at the organization role your identity provider asserts (**Viewer** by default, **Admin** on a fixed attribute) and to the connection's provisioned access, the projects you selected at the role you set for each. An invitation or Directory Sync still takes precedence over JIT.

See [Just-in-Time Provisioning](/identity/sso/jit-provisioning) to set the provisioned access and map the `stackone_role` attribute that grants organization admin.

<Note>
  JIT is turned on per connection with the **Enable JIT** action on the **Just-in-time provisioning** card of the **Provisioning** tab. With it off, SSO authenticates a member but organization membership comes from an invitation or Directory Sync.
</Note>

## Require SSO

Once your connection is verified, you can require members to sign in through SSO and turn off email and password sign-in. Open **Organization > Security > Authentication**, edit the **Enforcement Policy**, and add your SAML connection to the **Enforced methods**.

<Frame>
  <img src="https://mintcdn.com/stackone-60/y1H5HYQCzx5b5iEx/images/identity/sso/sso-enforcement.png?fit=max&auto=format&n=y1H5HYQCzx5b5iEx&q=85&s=a752b9afac0105d9c25dbfe077b0a2a1" alt="The Enforcement Policy panel under Organization > Security > Authentication, where you add your SSO connection to the enforced sign-in methods." data-og-width="1568" width="1568" data-og-height="191" height="191" data-path="images/identity/sso/sso-enforcement.png" data-optimize="true" data-opv="3" srcset="https://mintcdn.com/stackone-60/y1H5HYQCzx5b5iEx/images/identity/sso/sso-enforcement.png?w=280&fit=max&auto=format&n=y1H5HYQCzx5b5iEx&q=85&s=8e34e292c15002c4ffbfc1e85de03d5e 280w, https://mintcdn.com/stackone-60/y1H5HYQCzx5b5iEx/images/identity/sso/sso-enforcement.png?w=560&fit=max&auto=format&n=y1H5HYQCzx5b5iEx&q=85&s=acb10e7ca6c44b58ba2370225b15f840 560w, https://mintcdn.com/stackone-60/y1H5HYQCzx5b5iEx/images/identity/sso/sso-enforcement.png?w=840&fit=max&auto=format&n=y1H5HYQCzx5b5iEx&q=85&s=44e0853fa83e6fcfb68c2cb23b939dc6 840w, https://mintcdn.com/stackone-60/y1H5HYQCzx5b5iEx/images/identity/sso/sso-enforcement.png?w=1100&fit=max&auto=format&n=y1H5HYQCzx5b5iEx&q=85&s=a1a3e7b205a03e28c7f36301e0db7f37 1100w, https://mintcdn.com/stackone-60/y1H5HYQCzx5b5iEx/images/identity/sso/sso-enforcement.png?w=1650&fit=max&auto=format&n=y1H5HYQCzx5b5iEx&q=85&s=9288ebd294665d4b5de5e223f07c87bb 1650w, https://mintcdn.com/stackone-60/y1H5HYQCzx5b5iEx/images/identity/sso/sso-enforcement.png?w=2500&fit=max&auto=format&n=y1H5HYQCzx5b5iEx&q=85&s=84225194b7194fa7d7574da358ca523a 2500w" />
</Frame>

You can only enforce a connection whose domain is verified. The **Enforcement Policy** won't let you save an unverified method, so a misfire there can't lock members out. It does not, though, check that sign-in actually works: a verified domain whose SAML app is misconfigured, your account isn't assigned to the app, or a certificate or issuer mismatch, still enforces, and enforcement disables password sign-in for everyone at once.

<Warning>
  Before you enforce SSO, confirm sign-in works end to end. Open a private or incognito window and complete an SSO sign-in as a member who is assigned to the app in your IdP, not only your own account. Enforce only after that succeeds, because enforcing turns off password sign-in and anyone your IdP cannot authenticate is locked out.
</Warning>

<Note>
  Locked out after enforcing? An Org Admin who can still reach the dashboard can remove the method under the **Enforcement Policy** to restore password sign-in. If no one can get in, contact StackOne support.
</Note>

## Next steps

<CardGroup cols={2}>
  <Card title="Okta" icon="key" href="/identity/sso/okta">
    Connect Okta as your SAML identity provider.
  </Card>

  <Card title="Microsoft Entra ID" icon="microsoft" href="/identity/sso/microsoft-entra">
    Connect Microsoft Entra ID (Azure AD) as your SAML identity provider.
  </Card>

  <Card title="Any SAML 2.0 provider" icon="shield-halved" href="/identity/sso/saml-generic">
    Connect any identity provider that supports SAML 2.0.
  </Card>

  <Card title="Just-in-Time Provisioning" icon="user-plus" href="/identity/sso/jit-provisioning">
    Create members on first sign-in and map an attribute to organization admin.
  </Card>

  <Card title="Directory Sync" icon="arrows-rotate" href="/identity/scim/overview">
    Provision and deactivate members automatically from your IdP.
  </Card>

  <Card title="Groups" icon="users" href="/identity/groups/overview">
    Grant many members the same project or account access at once.
  </Card>
</CardGroup>
