How to set up Magento 2 to use your SSL certificate

Learn how to configure your Magento 2 store to use SSL certificates using either the Magento 2 Dashboard or SSH.
Get fast, reliable hosting for WordPress
Power your site with the industry’s fastest, most optimized WordPress hosting
Purpose
SSL certificates create an encrypted link between a server and a client. A functioning SSL allows users to transmit sensitive information between servers and browsers without fear of third-party eavesdropping. For more information about SSL certificates and how they function, see What are SSL certificates?
Using your dashboard
If you have not already purchased an SSL certificate, either visit our website or contact our sales team, available 9 a.m–5 p.m. eastern time (ET), Monday through Friday. Otherwise, use the procedure below to configure Magento to use your SSL certificate:
- Log in to your Magento 2 Dashboard.
- Select Stores > Configuration.

- On the Configuration page, from the General list, select Web.

In the Base URLs (Secure) section, take the following action:

- In the Secure Base URL field, enter “https://” followed by your domain.
- In the User Secure URLs in Frontend drop-down list, select Yes.
Click Save Config. Your store is now configured to use your SSL certificate.
Using SSH
- Login to your Liquid Web server.
- Navigate to your Magento installation, but replace the bracketed placeholders accordingly:
cd /home/[user]/[domain.tld]/html/
- Choose one, but replace all bracketed placeholders accordingly:
- Enable secure URLs in both the customer-facing and admin-only areas of your store:
php bin/magento setup:store-config:set --use-secure=1 --base-url=”https://[domain.tld]”
- Enable secure URLs in the admin-only areas only:
php bin/magento setup:store-config:set --use-secure-admin=1 --base-url=“https://[domain.tld]”
- Enable secure URLs in both the customer-facing and admin-only areas of your store:
Additional resources
http://devdocs.magento.com/guides/v2.0/install-gde/install/cli/install-cli-subcommands-store.html
For 24-hour assistance any day of the year, contact our support team by email or through your Client Portal.
Additional resources
A guide on how to backup your Magento 2 store →
Discover how to back up Magento to protect store data and support easier recovery.
What is ecommerce fraud? Plus tools for fraud protection →
Explore fraud protection tips to help secure transactions and reduce store risk.
Magento tasks to keep your store running smoothly →
Use this maintenance checklist to keep your store secure, updated, and running smoothly.



