How to Set Up Let’s Encrypt SSL Certificate
Introduction
Let’s Encrypt provides free SSL certificates, making it easy to secure your website with HTTPS. This guide shows you how to install a Let’s Encrypt SSL certificate on your server using Certbot.
Step-by-step Guide
- Update your package list and install Certbot
- For Nginx:n
- sudo apt update
- sudo apt install certbot python3-certbot-nginx
- For Apache:n
- sudo apt update
- sudo apt install certbot python3-certbot-apache
- For Nginx:n
- Obtain and install the SSL certificate
- For Nginx:n
- sudo certbot --nginx
- For Apache:n
- sudo certbot --apache
- Follow the prompts to enter your domain and email.
- For Nginx:n
- Verify SSL installation
- Visit
https://your_domain.comin your browser. - You should see the padlock icon indicating a secure connection.
- Visit
- Set up automatic certificate renewal
- Certbot sets up automatic renewal by default, but you can test it with:n
- sudo certbot renew --dry-run
- Certbot sets up automatic renewal by default, but you can test it with:n
- (Optional) Check renewal logs
- cat /var/log/letsencrypt/letsencrypt.log
Recommendations
- Always use HTTPS for all your sites to protect user data.
- Make sure your domain points to your server before running Certbot.
- Regularly check that your certificate renews automatically.
Call To Action
Want secure hosting with free SSL? Check out our VPS plans! https://xernode.com/#pricing