http/1 and http/2 parallel delivery using nginx

Is it possible to have both http/1 and http/2 enabled for a vhost in nginx?

The idea is to broaden the supported browsers by serving http/2 if supported, and, if not, fall back to http/1.


This is automatically handled in the TLS handshake. The client sends a TLS extension called ALPN (Application-Layer Protocol Negotiation) in its initial handshake message, where it tells it supports HTTP/2.

The server then selects the protocol to use in the connection depending on client capabilities.