---
title: "Set up single sign-on | PackageMaze docs"
description: "Connect Okta, Microsoft Entra ID, or Google Workspace to your PackageMaze Organization over OpenID Connect, test it, require it, and what members and Tokens meet once it is on."
canonical: https://www.packagemaze.com/docs/single-sign-on/
---

> Documentation index: https://www.packagemaze.com/llms.txt

# Set up single sign-on

Connect your company identity provider so members sign in with their work account to open your Organization, and require it when you're ready.

## Who can set it up

An Organization Admin, on the Enterprise plan, in Organization Settings under **Single sign-on**. PackageMaze connects one identity provider per Organization over OpenID Connect: Okta, Microsoft Entra ID, or Google Workspace.

Everyone keeps their own PackageMaze account. Your identity provider doesn't create PackageMaze accounts; it only opens your Organization.

## Add PackageMaze to your identity provider

Do this first. Copy the **Redirect URI** from **Single sign-on** and register an OpenID Connect web application with it at your identity provider. The redirect URI never changes for your Organization, even if you remove the connection and connect again.

### Okta

- Admin Console: create an app integration, sign-in method **OIDC - OpenID Connect**, type **Web Application**.
- **Sign-in redirect URIs**: the redirect URI. Grant type: **Authorization Code**.
- Assign the people or groups who should open your Organization.
- Issuer URL: your Okta domain, such as `https://acme.okta.com`, or your custom authorization server's issuer. A custom authorization server needs an access policy that includes this app.

### Microsoft Entra ID

- Entra admin center: **App registrations**, new registration, **Single tenant only**.
- Add a **Web** redirect URI: the redirect URI.
- **Certificates & secrets**: create a client secret, copy its **Value**, shown only once, and note its expiry.
- **Enterprise applications**, your app, **Properties**: **Assignment required** **Yes**. Then assign the people, or groups with Entra ID P1 or P2, who should open your Organization. A Global Administrator gets in regardless, so test with a member.
- **API permissions**: **Grant admin consent**, or members see "Need admin approval".
- Issuer URL: `https://login.microsoftonline.com/<tenant-id>/v2.0`, with the **Directory (tenant) ID** from the app's **Overview**.
- An app registration that uses a custom signing key isn't supported.

> **Watch out:** Entra identifies each person differently for every app registration. When the secret nears expiry, add a new secret to the same registration and use **Replace secret** in PackageMaze. If you create a new registration instead, every member has to connect again.

### Google Workspace

- Google Cloud console, **Google Auth Platform** > **Get started**: name the app, choose the **Audience**, add a contact email, and agree to Google's user data policy.
- **Audience**: choose **Internal** if your project is in your Workspace's Google Cloud organization. Only your Workspace's accounts can then sign in. With **External**, Google blocks every sign-in until you publish the app, or add each person under **Audience** > **Test users**.
- **Clients** > **Create client**, type **Web application**. **Authorized redirect URIs**: the redirect URI. Copy the client secret, shown only once.
- Issuer URL: `https://accounts.google.com`.
- Workspace domain: your Workspace's primary domain, such as `acme.com`, from the Google Admin console under **Account** > **Domains** > **Manage domains**.

PackageMaze signs in only accounts in that Workspace: a personal Google account, or one from another Workspace, is refused. Google can take from five minutes to a few hours to apply a new client. If **Test connection** fails at Google right after setup, wait and try again. Google deletes a client unused for six months.

> **Watch out:** Use an issuer that only your company's people can sign in to. A public one, where anyone can create an account, would let anyone through.

## Connect and test

In **Identity provider**, enter the **Issuer URL**, **Client ID**, and **Client secret**, plus the **Workspace domain** for Google, and save. PackageMaze stores the secret encrypted and never shows it again.

**Test connection** signs you in through your identity provider and connects your own account, the same way members will. The connection then shows **Tested**.

For your identity provider's app tile, copy the **Sign-in address** from Organization Settings, Single sign-on. It opens your Organization's sign-in page, where members press **Continue**.

## Require it

On **Require for all members**, press **Turn on**. Members then sign in at your identity provider to open the Organization, at most once every 24 hours in each browser. Turning it on doesn't remove anyone.

Before it turns on, save your Organization's single sign-on recovery codes with **Download** or **Copy**. They let an Admin open the Organization when the identity provider is down or misconfigured: open the **Sign-in address** shown in Organization Settings, Single sign-on, and choose **Use a recovery code**. Each works once, and **Make new codes** replaces the old ones. Keep at least two Admins who sign in to PackageMaze with their own passkey, password, or GitHub: only they can use a code, and PackageMaze won't let you remove the last one.

## Members

- **First time:** they open the Organization signed in with their own account, sign in at the identity provider, and press **Connect** on the screen that connects the two. After that, signing in at the identity provider alone opens the Organization.
- **New people** join the usual way, through your GitHub Join rule or an Invitation, then connect the first time they open the Organization.
- **Signed in as the wrong person** at the identity provider: press **Not me**, sign out at the identity provider, and open the Organization again.

Members can't change a connection themselves. An Admin can disconnect one member in People, and they connect again the next time they open the Organization. If the wrong account connected, fix it at the identity provider first.

## Tokens and Agents

A member's Tokens and Agents are paused until they sign in through your identity provider once. Then they work again until they expire: at most 365 days for a Static Token, 90 days for an Agent. CI and Autonomous Agent credentials are never paused. Creating, renewing, or widening one, approving `maze auth login`, and approving an Agent's access need a recent sign-in at your identity provider. Revoking or narrowing never does.

> **Note:** When someone leaves, remove them from your Organization as well as deactivating them in your identity provider. Removing them stops their Tokens and Agents within a minute.

## Remove the connection

**Remove connection** asks you to type your identity provider's host to confirm. It removes every member's connected identity with it. If you connect again later, with the same redirect URI, everyone connects again the first time they open the Organization.

## If sign-in fails

The failure page says what happened and offers **Try again**. Admins see recent failures, kept for 90 days, under **Failed sign-ins**: usually a wrong redirect URI, Issuer URL, or secret. An identity provider that shows its own error page never sends the attempt back, so PackageMaze records nothing: fix it at the identity provider, using its sign-in log. If Entra shows members "Need admin approval", grant admin consent. If it shows AADSTS50105, assign them to the app. Meanwhile an Admin opens the **Sign-in address** and chooses **Use a recovery code**.

Next: [Leaving PackageMaze](https://www.packagemaze.com/docs/leaving-packagemaze/)

Related: [The PackageMaze GitHub App](https://www.packagemaze.com/docs/github-app/), [Leaving PackageMaze](https://www.packagemaze.com/docs/leaving-packagemaze/)
