Allow Access to .well-known Folder For Let’s Encrypt/Certbot When Site Is Protected By HTTP Authentication

If you’re running Apache web server and you have your site protected with HTTP authentication but still want to allow Let’s Encrypt/Certbot to be able to issue a certificate you will have to allow access to the .well-known folder on your site. Otherwise they may give you an error and fail to issue you a certificate.

You can allow access to individual folders within that site by creating a .htaccess file in the folder (in this case within the .well-known folder) with the following contents:

This will allow anyone to access that folder thus allowing Let’s Encrypt/Certbot to verify your domain and issue you a certificate.

Leave a Reply

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