Online tool to check server HTTP/2, ALPN, and Server-push support.

How to enable HTTP/2 support in NGINX

Last updated: 05 Jan 2017

Nginx 1.9.5 and later versions have HTTP/2 support. Most of the default repositories on Ubuntu/Debian and RHEL/CentOS has versions later than 1.9.5, so we skip the upgrading part.

Add HTTP/2 Support

We highly recommend you enable HTTPS support for your web site first. Most web browser simply do not support HTTP/2 over plain text. Besides, there are no excuses to not use HTTPS anymore. HTTP/2 can be enabled on a site-by-site basis. Locate your site's corresponding configuration file, and add http2 to its listen directive. Overall, your configuration file should look something like this:
server {
    listen 443 ssl http2;

Push resources

Unfortunately, neither Nginx open source nor Nginx Plus support HTTP/2 Server push yet. As of now, Apache supports HTTP/2 Server Push. For most of the users lack of this feature is not a deal breaker. Nginx supports a good portion of the HTTP/2 spec. If Nginx ever supports Server Push, chances are higher that it will be an Nginx Plus feature.