Online license management
Learn how to retrieve, setup, stage and request new online SonarQube Server license.
To run SonarQube Server, you need a license that corresponds to the plan you purchased, including the SonarQube Server edition, Lines of Code (LOC), staging licenses, commercial support, and additional features such as Advanced Security. See Plans and Pricing for more information about the different editions and features.
Contact sales to request the license key or email us at [email protected].
After your purchase is confirmed, you will receive a license key. If the license key follows this format XXXX-XXXX-XXXX-XXXX, continue reading this page. Otherwise, see Server ID based license key.
Permissions
To manage your licenses and additional features in SonarQube Server you must have the Administer System permission.
To apply the permission to users or groups go to Administration > Security > Global Permissions and select the Administer System check box.
Activating your license
To activate your SonarQube Server license:

Go to Administration > Configuration > License Manager.
Click Add license button to open a modal.
Enter your license key in the modal and accept the terms and conditions.
Click Set license to confirm.
An internet connection is required to activate your license. Your instance should be allowed to reach the following resources: https://api.prod.sonarsource.licensespring.com
Activating your license offline
If your SonarQube Server instance is offline and cannot reach the online resource listed in the previous section after you enter the license key, you will have to choose the Activate offline option.

Then follow these steps:

Click Download .req file, to download the request file to your computer. You will need this file in the next step.
Upload this .req request file to the activation page that opens in a new tab. The license activation URL is
https://offlinelicense.sonarsource.comand it will automatically trigger the download of a .lic license file to your computer.Click Upload .lic file and locate the lic. file to upload it into your SonarQube Server instance to complete the activation.
SonarQube Server license page
Once your activation has been completed you will see the following information on the SonarQube license page.

Click Set a new license and enter a new license key to replace your current license. Click on the dropdown menu and select Unset license to remove it. See Online license management for more information.
Click Refresh license to fetch all the up-to-date information about the license from the license server. This is required if the license was changed by Sonar to update, for example, the maximum LOC. To refresh the offline activated license you can use Set a new license with the same license key.
License information:
Edition: This is based on the plan you had purchased (Developer, Enterprise or Data Center).
Type: Type of license, the options are production, test and evaluation.
Start date: Displays the license start date.
Expiration date: Displays when the license expires.
Support included: Indicates whether commercial support is included in your license.
Activation method: Displays whether the license was activated online, offline or is based on server ID.
License key currently used.
License usage:
Lines of code (LOC): Shows the number of LOC currently analyzed out of the total allowed by your license.
Notification threshold: Shows the LOC threshold that triggers email notification. A reminder is sent two months and again one month before your license expires. Click the Edit notification threshold to change it. See Checking your LOC consumption for more information.
Additional features: Lists all the extra features your organization has purchased. It shows the feature’s name, start and expiration dates, availability and enablement.
Changing server ID
To move your license to an instance with another server ID you have to unset it on the current instance. To unset the license click on the dropdown menu next to Set a new license button and select Unset license to remove it. Unsetting a license removes it from the system.
Staging license
A staging license is available in Enterprise and Data Center editions, or in editions with commercial support. Your staging license may include one or more activations, which you can use for non-production instances to test new features, for update purposes, new integrations, and other purposes.
The process of activating staging licenses is the same as for production.
License user portal
As soon as a license is created, your organization will receive an email with access to the License user portal, where you can see all available licenses.
Logging into the License user portal
Sonar License user portal is available at http://license.sonarsource.com/.
Access to the license user portal requires your email address to be registered by Sonar as a license manager for your organization.
It is recommended to log in using one of the available Single Sign-On (SSO) authentication providers.
If this is your first time logging in and you are using an email address instead of an SSO provider, you must first Sign up to create an account.
Your existing Help Center account credentials are also valid for accessing the License user portal.
Checking the license status

To retrieve the license’s status:
Click on Licenses in the left-side navigation to see a list of all licenses for your organization.
Select a license and navigate to the Devices tab.
The Devices tab contains a list of SonarQube Server instances. The Status column shows the status of the license on that instance, Active or Inactive. Note that the Hardware ID column shows the server ID of your SonarQube Server.

License key isn't working
If your license key isn't working, send an email to [email protected] that includes the following information:
Server ID found under Administration > System.
SonarQube Server version found under Administration > System.
Clarify which existing license (production or staging) and server ID it is replacing.
Confirm the status of the existing license.
A new license key will be issued within one business day once we receive an email with the required information at [email protected].
Related pages
License administration: server ID based activation method
Last updated
Was this helpful?

