"Unable to find virtual host listening on port 80" but I am running apache with no virtual hosts

Please fill out the fields below so we can help you better. Note: you must provide your domain name to get help. Domain names for issued certificates are all made public in Certificate Transparency logs (e.g. https://crt.sh/?q=example.com), so withholding your domain name here does not increase secrecy, but only makes it harder for us to provide help.

My domain is: nebula.lucidgreen.com

I ran this command: sudo certbot --apache -d nebula.lucidgreen.com

It produced this output: Unable to find a virtual host listening on port 80 which is currently needed for Certbot to prove to the CA that you control your domain. Please add a virtual host for port 80.
Ask for help or search for solutions at https://community.letsencrypt.org. See the logfile /var/log/letsencrypt/letsencrypt.log or re-run Certbot with -v for more details.

My web server is (include version): Apache/2.4.62 (Amazon Linux)

The operating system my web server runs on is (include version): Amazon Linux 2023

My hosting provider, if applicable, is: AWS

I can login to a root shell on my machine (yes or no, or I don't know): yes

I'm using a control panel to manage my site (no, or provide the name and version of the control panel): no

The version of my client is (e.g. output of certbot --version or certbot-auto --version if you're using Certbot):certbot 3.2.0

If you want Certbot to get the certificate using the --apache plugin and the automatic installation of the certificate into Apache done by Certbot, it requires a port 80 HTTP VirtualHost to do so. (Because it searches and modifies that vhost for the HTTPS vhost on port 443.)

The alternative is to get a certificate using the webroot authenticator and installing the cert into Apache manually. See User Guide — Certbot 3.2.0 documentation for the documentation of the webroot plugin.

3 Likes