Enable SSL on BitBucket Server

BitBucket Server alloow you to host git repositories. By default bitbucket server have url in following format

To install SSL, first point a domain to the server IP.

Install nginx

Now install LetsEncrypt

Get SSL in standalone mode. We use standalone mode because nginx will proxy all request to bitbucket server, so SSL validation will be difficult using nginx.

In this example, i will be using git.serverok.in, you need to replace with your actual domain.

Edit file


Add before

Create file


Restart nginx server

Edit file

At end of the file, add following code

Now login to Bitbucket server, Go to Bitbucket Server administration area and click Server settings, and change Base URL to

bitbucket server

Restart bitbucket server

Need help with Linux Server or WordPress? We can help!

Leave a Reply

Your email address will not be published. Required fields are marked *