Set up Enterprise SSO through your WorkOS account
Let a company you sell to sign its people in with its own identity provider, SAML or OIDC, through your own WorkOS account, step by step.
Enterprise single sign-on lets the people of a company you sell to sign in to your app with their company account: Okta, Microsoft Entra ID, Google Workspace, or any SAML or OIDC identity provider. Your login page shows Continue with SSO, they type their work email, and their company's identity provider does the rest. It runs through your own WorkOS account: BuildBase keeps your WorkOS client ID and an encrypted API key, makes one WorkOS organization per company, and runs the sign-in itself. WorkOS bills your account for each connection; see WorkOS pricing for its current rates. This guide is the setup in order; Enterprise SSO is the full reference.
Before you start
- A WorkOS account, with its staging environment for testing and production for real companies.
- An auth client with a login page, and an owner or admin role in the BuildBase console.
- A plan that includes Enterprise SSO.
What goes where
| Copy this | From | Paste it into |
|---|---|---|
| Client ID | WorkOS, the environment's API Keys page | BuildBase, Authentication, Enterprise |
| API key | WorkOS, the same page (create one) | BuildBase, the same tab |
| Redirect URI | BuildBase, the Enterprise tab once the key is saved | WorkOS, the application's Redirects, as the default |
| The company's domain | The company | BuildBase, the enterprise's Email domains; WorkOS verifies it |
1. Open the Enterprise tab
Open the Enterprise tab in the console
(opens the console in a new tab)In the rail choose Users, then Authentication under Access, and the Enterprise tab.

2. Connect your WorkOS account
In WorkOS, on the environment's API Keys page, copy the client ID (client_...) and create an API key (sk_...), both from the same environment. Paste them into Client ID and API key on the Enterprise single sign-on card, and press Save and validate. BuildBase checks the key with WorkOS before it stores anything.

3. Register the redirect URI in WorkOS
The card becomes WorkOS provider: your client ID, a preview of the key, the Redirect URI and when the key was last checked. Copy the redirect URI into WorkOS, under the application's Redirects, and make it the default. Leave AuthKit off in that environment: BuildBase uses WorkOS for single sign-on only. Check the key checks it again at any time.

4. Add the company
Press Add enterprise. In Add an enterprise, type the Company name, keep Create accounts on first sign-in on unless the company's people must already have an account, and press Add enterprise. BuildBase makes the company's organization in your WorkOS account.

5. Add its email domain
The company's page opens. Under Email domains, type the company's domain and press Add domain. It reads Pending until the company's IT admin publishes the DNS record WorkOS shows them; then Refresh from WorkOS reads it as Verified. Only a domain WorkOS verified sends anyone to the company's sign-in.

Once the record is published and WorkOS has checked it:

6. Hand the connection to the company's IT admin
Under Connect the identity provider, type the IT admin's address in Invite the IT admin by email, tick Domain verification so the same email covers the domain, and press Send invitation. Or Open the setup portal now on a call together. They connect their identity provider in WorkOS's setup portal and never need a BuildBase account; send them the page for IT admins. Identity providers on the same page shows the connection once it is active.

Once they have finished in the portal, Identity providers lists the connection as Active (press Refresh to read it from WorkOS again):

7. Turn sign-in on
Back on the Enterprise tab, turn Sign-in on in the WorkOS provider card.

8. Add the Enterprise SSO method
On the Methods tab press Add auth method, choose Enterprise SSO, keep or change its Title, and press Create. Then attach it to each auth client whose login page should offer it: on the Settings tab, Edit on the client, tick the method under Methods, and Update.

9. Choose the company's workspaces
On the company's page, under Workspaces, pick a workspace, Add workspace, and press Save workspaces. Its people join those workspaces the first time they sign in through the company (step 6 of the reference).

10. Sign in
Your login page now offers single sign-on. Beside your other ways in, its button reads Single sign-on (screen readers hear "Continue with SSO").

Pressing it asks for a Work email. The person types theirs and presses Continue with SSO; their company's identity provider does the rest. Where single sign-on is the page's only way in, the Work email box shows straight away, with no button to press first.

Check that it worked
Sign in with a test user from your WorkOS staging environment's identity provider. The person appears in the company's People, lands in the workspaces you chose, and Activity shows the sign-in.

Things to watch out for
- Turn Sign-in on before adding the method. While enterprise sign-in is off, adding an Enterprise SSO method is refused with 409
enterprise_not_enabled: "Configure WorkOS and turn enterprise sign-in on, on the Enterprise tab, before adding the method." - Keep the client ID and the key from one environment. A staging key with a production client ID passes every check until the first sign-in, which then fails.
- Require single sign-on only once the connection is active. With it on, the company's people are refused at every other way in (a password, a code, a passkey, a wallet, a social button, the second step of two-step), and until the connection works they cannot sign in at all. Its access policy can instead narrow the other ways, down to passkeys only.
- A domain counts only while WorkOS verifies it. A pending domain routes nobody, and a subdomain is its own entry: the email the identity provider sends must be on a verified domain of that company, exactly.
- Attach the method to every client the company's people use. A login page without single sign-on leaves them a sentence that points at a button the page does not have.
- A sign-in screen of your own sends a PKCE challenge. PKCE is a check that the sign-in finishes in the same browser that started it, and the hosted page does it for you. Continue with SSO sends an S256 challenge, and the start refuses a request without one. So the code the identity provider sends back works only in the browser that pressed the button. If you build your own screen against the start, it must make a verifier, send its challenge and redeem the code with it (how).
Next steps
- Enterprise SSO - the company's access policy, roles, provisioning and audit trail.
- Sign-in setup guides - every other way to sign in.