To generate a letsencrypt certificate without installing it into Apache, do:

# sudo certbot certonly --webroot \
  --webroot-path /path_to_your_vhosts/ -d \
  --webroot-path /path_to_your_vhosts/ -d

# apache2ctl configtest

If the configtest does not detect any problems reload the Apache server:

# service apache2 reload


  1. How to Set Up Let’s Encrypt Certificates for Multiple Apache Virtual Hosts on Ubuntu 14.04
  2. Letsencrypt with webroot on Apache
  3. Letsencrypt (for WordPress sites)
  4. Certbot Users Guide
  5. Name-Based VirtualHosts and SSL
  6. Using Multiple SSL Certificates in Apache with One IP Address
Letsencrypt Certificate – Manual Install