In this blog I will be showcasing the SonarQube server installation and setting-up an external PostgreSQL Database to it.
There are some pre-requisites for installing SonarQube Server and you can follow the below documentation link for the same.
You can download the SonarQube server from the below link.
Once you click on the link, you will see below page where you can download the required version of SonarQube.

For this Blog I am going to download the community build version.
Once downloaded I have extracted the file.

I am navigating to the bin file and then click on the Windows where I see the Start and Stop Batch Files of Sonar.

Once I run StartSonar as administrator, the SonarQube will start and become Operational.

SonarQube’s default port is 9000, you can access it locally using this URL- http://localhost:9000
Once you click on in, you will be prompted for the username & password.
The default username and password are admin.

Once you click on login, you will be prompted to update your password.

Enter the old password as admin and enter the desired password in new password and click on update.
Once done you are ready with SonarQube server, and you will be redirected to homepage of SonarQube.

Here you see an error- Embedded database should be used for evaluation purposes only. It doesn’t support scaling, upgrading to a new SonarQube Server version, or migration to another database engine
We can eliminate this by integrating it to PostgreSQL
Now, let’s download install PostgreSQL.
You can use https://www.postgresql.org/download/ to download PostgreSQL.
I will select the windows option then I will get the below screen, where I will be clicking on the Highlighted option.

Here I will be selecting the latest version for the download.

Once Downloaded the file can be see under downloads and as it is exe file, I will double click on it to execute it.

Once I double click on it, setup Wizard will be opened.

You can start clicking on Next – Next, till you land to below page.
Here you need to provide the Password for the SuperUser and click next.

You can leave the Port number as default and click next.

And if you click on Next – Next again you will land on below where you see the Installation happening.

Once done you can click on the finish and the installation is done.
In the search check for pgAdmin and click on it. It will open the below, where you can give the password and click on OK.

Once you click on OK then you will see below screen.

Now we will create a database for SonarQube.

Give the name as sonarqube and click on save.

Once the database is created, create a sonaradmin -user with superuser permissions.


And switch to that user.
We need to modify the properties file in the Config folder.
For me this is the path- C:\Program Files\SonarQube\sonarqube-25.3.0.104237\sonarqube-25.3.0.104237\conf
I have updated the below in the file.

Once done, then you restart the SonarQube.
Please delete previous data files before restarting.
I have this as path for data- C:\Program Files\SonarQube\sonarqube-25.3.0.104237\sonarqube-25.3.0.104237\data
Once restarted, it might prompt for password, give it as admin and then it will ask to reset.

Now you do not see any error on the home page.
This is how you integrate SonarQube with PostgreSQL.
We’re a SonarQube Gold Partner. For licensing, demos, or implementation, reach out to devops@ecanarys.com
Canarys is a SonarQube Gold Partner, delivering end-to-end DevOps solutions using Atlassian, GitLab, GitHub, Azure DevOps, Kubernetes, and more serving clients across 30+ cities in India, APAC, and the USA.