This guide explains how to enable Apache’s HTTP/2 module on a cPanel & WHM server. HTTP/2 allows a browser to request multiple website resources over one connection. The steps require server administrator access and a compatible Apache and PHP configuration.
Check compatibility first
HTTP/2 requires HTTPS with a valid certificate. In EasyApache 4, the http2 module is incompatible with the prefork and itk processing modules and with mod_ruid2. A processing module controls how Apache handles requests; changing it can also affect how PHP runs.
Review the PHP handler and all affected websites before changing Apache modules. Do not accept automatic removals without understanding them. Sites using the DSO PHP handler need a compatible alternative before switching away from prefork.
These instructions concern Apache on a cPanel server. A separate NGINX front end has its own HTTP/2 configuration.
Enable HTTP/2 through WHM
-
Open Software > EasyApache 4 in WHM.
-
Select Customise for the currently installed profile.
-
Review Apache MPM and select a compatible processing module, such as
event, only after confirming PHP compatibility. -
Under Apache Modules, select
http2. -
If a conflict message appears, review the proposed changes. Stop and resolve dependencies if the removals would disrupt your sites.
-
Open Review and check every package to be installed or removed.
-
Select Provision when the changes are correct, and wait for completion.
-
Test the websites. If an Apache restart is required, use Restart Services > HTTP Server (Apache).
Install the module from the command line
This alternative applies only to cPanel EasyApache 4 servers running AlmaLinux or Rocky Linux that already have a compatible processing module and PHP handler. It is not a procedure for installing HTTP/2 on a server without cPanel.
Connect through SSH as root and run:
dnf install ea-apache24-mod_http2Review the package manager’s proposed transaction before confirming. If it reports incompatible modules or proposes unexpected removals, stop and resolve the configuration through EasyApache 4. Do not remove the active processing module in a separate transaction.
If required after installation, restart Apache using cPanel’s service script:
/usr/local/cpanel/scripts/restartsrv_httpdCheck the result
Run httpd -M on the server and confirm that http2_module is listed with the expected processing module. Then open a website over HTTPS and use your browser’s network tools to check that requests use the h2 protocol. A module appearing in the list alone does not prove that a browser connection uses HTTP/2.






