Set up SSO
How to set up Single Sign-On (SSO) in your enterprise by using the SonarQube Cloud setup assistant.
This feature requires the SonarQube Cloud's Enterprise plan.
To set up SSO in your enterprise, you must be the administrator of the enterprise in SonarQube Cloud.
Start the SSO setup assistant
In SonarQube Cloud, retrieve your enterprise. See Retrieving and viewing your enterprise for more details.
Go to Administration > SSO & provisioning. The SSO & provisioning page opens.

Expand the Single sign-on section and select Set up SSO to open the Configure Single Sign-On setup assistant in a new tab.
On the Set up SonarSource screen, select Get Started.

On the Select Your Identity Provider step, select Okta or Entra ID. If your provider is not listed, select Custom SAML or Custom OIDC under Provider Not Listed?. Then select Next.
Follow the instructions below for your selection:
If using Okta OIDC

Setting up SSO with Okta moves between two interfaces: the SonarQube Cloud SSO setup assistant (see Start the SSO setup assistant) and the Okta Admin Console. Okta occasionally changes its own UI, so treat the setup assistant as the source of truth for field names and step order, and expect the Okta labels below to differ slightly from what you see.
Step 1: Create application
The setup assistant walks you through creating the application and does not call out that your access-control choice here determines whether you will need Step 4: Assign Access.
Follow the instructions in the SSO setup assistant to create the application in Okta.
Assignments Under Controlled access, choose one of the following options:
Allow everyone in your organization to access: grants access to all users in your Okta organization. If you also enable immediate access with Federation Broker Mode, Okta automatically assigns all groups to the application, so you can skip Step 4: Assign Access.
Limit access to selected groups: select the specific groups that should have access. If you choose this option, you can skip Step 4: Assign Access.
Skip group assignment for now: defer the access decision. If you choose this option, you must complete Step 4: Assign Access.
Then select Next to go to the step 2. Configure Connection.
Step 2: Configure connection
The setup assistant asks for values it does not show you how to find. This step points you to where each one lives in Okta.
Go back to Okta and select your account / name profile in the top-right corner.
Copy your Okta organization URL / domain.

Paste the copied value to the Okta Domain field in the setup assistant.

In Okta’s SonarQube Cloud application, go to General > Client Credentials.
Copy the value of the Client ID field.

Paste the copied value to the Client ID field in the setup assistant page.
Go back to your Okta’s SonarQube Cloud application and copy the client secret.

Paste the copied value to the Client Secret field in the setup assistant page.
In the bottom right corner of the assistant, select Create Connection and then Proceed. SonarQube Cloud is trying to connect to your Identity Provider. If the connection is established, the assistant moves to step 3. Claims Mapping.
Step 3: Claims Mapping
This step takes place entirely in the Okta Admin Console.
Note: This step is mandatory. The groups that match the filter below are sent as claims to SonarQube Cloud whenever a user logs in, independent of which groups you assigned access to the application in Step 4.
In the Okta Admin Console, go to Applications and Resources > Applications, select your SonarQube Cloud application, and go to Sign On.
Go down to the Token claims section, open the Show legacy configuration panel, and go to Group Claims.
Select Edit.
Set the fields as follows:
Groups claim type: Filter
Groups claim filter:
First field:
groupsSecond field: Select Matches regex and set the value to
.*to match all groups in your organization, or use a more restrictive expression depending on your organization's needs.

Important: The filter type must be set to Matches regex. The default Starts with filter type does not work with
.*(which matches all groups) and will cause group sync to silently fail.
Select Save.
In the SonarQube Cloud's setup assistant, select Next to go to the step 4. Assign Access.
Step 4: Assign Access
Whether you need to complete this step depends on your choice in Step 1: Create application.
Note: If you already granted access while creating your application in Step 1: Create application by selecting Allow everyone in your organization to access with Federation Broker Mode enabled, Okta automatically assigned all groups to the application, so you can skip sub-steps 1-4 below and go directly to sub-step 5 to continue in the SonarQube Cloud setup assistant. The same applies if you selected Limit access to selected groups. If you selected Allow everyone in your organization to access without enabling Federation Broker Mode, or selected Skip group assignment for now, complete all the sub-steps below.
In the Okta Admin Console, go to Applications and Resources > Applications, select your SonarQube Cloud application, and go to Assignments.
Select Assign, then Assign to Groups (or Assign to People to assign individual users instead of groups).
Select the groups to assign to the application.
Select Done.
In the SonarQube Cloud's setup assistant, select Next to go to the step 5. Test SSO.
Step 5: Test SSO
Beyond running the connection test, this step also covers what to check in the results and how to start the optional domain verification.
Select the Test Connection button. The test is started and the results are displayed on the page.
Verify the JSON response. In particular, verify that the email and groups attributes are correct. If the test was successful, select Enable Connection and Proceed.

You can now verify your company's email domain to avoid one-time email verification during SSO login. To do so, expand the Domain verification section on the SSO & provisioning page and select Set up domain verification. For detailed instructions, see the Domain verification page.
Next steps
Go to the Set up SCIM step if you want to set up SCIM provisioning.
Go to the Invite users to sign in step to terminate your setup.
If using Entra ID OIDC

Setting up SSO with Microsoft Entra ID moves between two interfaces: the SonarQube Cloud SSO setup assistant (see Start the SSO setup assistant) and the Microsoft Entra admin center. Use the notes below alongside the matching step of the assistant. Microsoft occasionally changes its own interface. Treat the setup assistant as the source of truth for field names and step order, and expect the Microsoft Entra ID labels below to differ slightly from what you see.
Step 1: Create application
The setup assistant walks you through creating the application in Microsoft Entra ID, and the documentation adds no further instructions for this step.
Follow the instructions in the first step of the SonarQube Cloud’s setup assistant.
Select Next to go to step 2. Configure Connection.
Step 2: Configure connection
Use this step to find the Microsoft Entra ID values that the setup assistant asks for, such as the application (client) ID and the domain.
In the setup assistant, paste the secret value copied in the previous step to the Client Secret field.
In your Microsoft Azure application, go to Overview.
In Essentials, copy the Application (client) ID and paste it to the Client ID field in the setup assistant.
Retrieve your domain ID as follows:
In Microsoft Azure, select your account in the top right corner, and select Switch directory in the account menu.
In the list of directories, locate your tenant and copy the value in the Domain column.
Paste this value to the Microsoft Entra ID Domain field in the setup assistant.
Alternatively, retrieve your domain ID from the Settings > Custom domain names page of your application and copy the ID from the Name column.

In the assistant, select Create Connection and then Proceed. SonarQube Cloud is trying to connect to your Identity Provider. If the connection is established, the assistant moves to step 3. Claims Mapping.
Step 3: Claims Mapping
SonarQube Cloud retrieves groups with a Microsoft Graph permission that needs admin consent. Grant that consent before you continue.
Sign in to the Microsoft Entra admin center as an administrator who can grant tenant-wide admin consent. Go to Entra ID > App registrations and select the application you created in step 1.
Select API permissions > Add a permission > Microsoft Graph > Delegated permissions.
Find Directory in the list of permissions (scroll down or enter
Directoryin the search box) and expand it. SelectDirectory.Read.Alland then select Add permissions. The connection requests two Microsoft Graph permissions:Directory.Read.AllandUser.Read. Check thatUser.Readis also listed under Configured permissions. Microsoft adds it when you register an app in the portal.Select Grant admin consent for your tenant and confirm.
In the setup assistant, select Next. The assistant moves to step 4. Assign Access.
For the requested scopes and your options if you cannot grant consent, see the Microsoft Entra ID: Need Admin Approval error section of the Troubleshooting page.
Step 4: Assign Access
The setup assistant tells you how to assign access to the application you created, and the documentation adds no further instructions for this step.
Follow the instructions in the Specific Users or Groups tab of the setup assistant to assign either all users or a subset of users or groups to the app you created in the first step.
In the assistant, select Next. The assistant moves to step 5. Test SSO.
Step 5: Test SSO
Beyond running the connection test, this step also covers what to check in the results and how to start the optional domain verification.
Select the Test Connection button. The test is started and the results are displayed on the page.

Verify the JSON response. In particular, verify the email and groups attributes, and the OID claim. If the test was successful, select Enable Connection and Proceed.
You can now verify your company's email domain to avoid one-time email verification during SSO login. To do so, expand the Domain verification section on the SSO & provisioning page and select Set up domain verification. For detailed instructions, see the Domain verification page.
Next steps
Go to the Set up SCIM step if you want to set up SCIM provisioning.
Go to the Invite users to sign in step to terminate your setup.
If using Custom SAML
Step 1: Create and set up the SonarQube Cloud application in your identity provider
This step depends on your identity provider.
Step 2: Test the SSO connection
In your identity provider, assign the user groups to the SonarQube Cloud application (to be able to perform the test, at least one group or user must be assigned).
In the SonarQube Cloud's setup assistant, select the Test Connection button. The test is started and the results are displayed on the page as illustrated below.Step b: Test the SSO connection

If the test was successful, select Enable Connection and Proceed.
You can now verify your company's email domain to avoid one-time email verification during SSO login. To do so, expand the Domain verification section on the SSO & provisioning page and select Set up domain verification. For detailed instructions, see the Domain verification page.
Next steps
Go to the Set up SCIM step if you want to set up SCIM provisioning.
Go to the Invite users to sign in step to terminate your setup.
If using Custom OIDC
Select Custom OIDC in the SSO setup assistant if your identity provider is not listed under Select Your Identity Provider, and follow its instructions.
You need the following from your identity provider:
The URL of its OpenID Connect discovery document, which you enter in the OpenID Provider Configuration Endpoint field.
The Client ID and Client Secret of the application you create.
The assistant shows the Callback URL to paste into your identity provider. Some providers call this field Sign-in Redirect URI or Login Redirect URI.
Regardless of your chosen provisioning method, you must configure the groups attribute in the OIDC payload. On the Claims Mapping step, your identity provider must send the Email, Groups, Login, and Name claims that the assistant lists. SonarQube Cloud uses Groups to synchronize organization memberships. See Group setup is mandatory for more details.
On the Test SSO step, select Test Connection and check the result before you select Enable Connection.
After you enable the connection, you can verify your company's email domain. See the Domain verification page.
Next steps
Go to the Set up SCIM step if you want to set up SCIM provisioning.
Go to the Invite users to sign in step to terminate your setup.
Related pages
Related online learning
Last updated
Was this helpful?


















