How to install an SSL certificate in DirectAdmin

  SSL Installation instructions

Take the stress out of SSL installation and let our tech experts take care of it!

SSL installation on DirectAdmin

After you receive your SSL certificate from the Certificate Authority (CA), the next step is installing it on your site’s server. If you have DirectAdmin, perform the following steps: 

  1. As per the screenshot below, click the button in the top-left corner to navigate to your server’s main menu. Then, select User:
  2. Select the SSL Certificates button in the Account Manager panel:
  3. In the next section, select the second option: Paste a pre-generated certificate and key
  4. In the Key field, paste your SSL’s Private key

    Note: Your SSL’s Private key is generated simultaneously with the CSR code. If you use DirectAdmin to create the CSR code, the Private key is not saved automatically, so you must ensure to save it manually. The Private key features the following header and footer: —–BEGIN PRIVATE KEY—– and —–END PRIVATE KEY—–.

  5. In the Certificate field, paste the SSL certificate code you got from the CA, including —–BEGIN CERTIFICATE—– and —–END CERTIFICATE—–. You can also find the code in the yourdomain.crt file that you can download from your SSLs.com account.
    Open the file using a plain text editor such as TextEdit (for macOS) or Notepad (for Windows).
  6. Once you’ve pasted the certificate code, select the Force SSL with https redirect option located below the box. When an HTTPS redirect is enabled, it ensures your site visitors are automatically redirected to the secure version of the site. Once the box is ticked, click Save.
  7. Upload your SSL’s CA Bundle file (the file with the extension .ca-bundle) to DirectAdmin to finish installing it.

    You can find the CA Bundle file in the ZIP archive the CA emailed you. You can also find it in your SSLs.com account. Look for the file called: yourdomain.ca-bundle.Use Notepad (Windows) or TextEdit (mac OS) to open the file to copy its content in the TXT format needed for adding it to the DirectAdmin panel.

    • Select “Paste a pre-generated certificate and key” then SSL CA Certificate.
    • In the box, paste the contents of your .ca-bundle file and select Use a CA cert below. Then click Save.
  8. You should receive a message saying, “Success CA certificate is ok. Your site should be secure within a few minutes”. This means you installed your SSL successfully. Use this tool to check your SSL’s installation status: https://decoder.link

Troubleshooting the “Could not Execute your request” error

Sometimes you may get the message, “Could not Execute your request. SSL is not enabled for this domain” when you open the SSL Certificates section in your Account Manager. This means that the Disable SSL option has been selected. This option doesn’t allow SSL installation and prevents you from opening the SSL Certificates section. If the option is enabled you can neither turn it off in the user management area nor install your certificate.

You can only disable it through SSH. So you’ll need root access to the server where you have DirectAdmin via SSH. When you have logged in as a root user, open the domain’s configuration file by running the following command: 

sudo nano /usr/local/directadmin/data/users/USER/domains/DOMAIN.TLD.conf
  • nano is the command to open the .txt file. 
  • User is the name of the account where you will apply the changes.
  • DOMAIN.TLD is your domain name.

Find the field ssl=OFF and change it to ssl=ON in the configuration file. When you’re done,  save the changes by pressing CTRL+O, then exit the file with CTRL+X. Now the error should be fixed. 

Contact your hosting provider for help if the error is not fixed.