> ## Documentation Index
> Fetch the complete documentation index at: https://docs.gcore.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Сonfigure HTTP/2 on the origin

Our nodes support HTTP/2. This option is enabled on all servers by default. Thus, if a user's browser supports HTTP/2, a CDN delivers content via this protocol.

This standard is supported by Google Chrome, Opera, Mozilla Firefox, Internet Explorer 11, Safari, Amazon Silk and Microsoft Edge. However, at present HTTP/2 works in browsers only for https requests, so to use this option, add an SSL certificate to you CDN Resource.

If your server doesn't support HTTP/2 but a client requests CDN content via HTTP/2, a CDN will deliver the content via HTTP/2, other content — via your server protocol. Browsers can speak different protocols to different domains, and they are able to merge the content they receive from those different domains into a single page.

## Server configuration

We recommend configuring your web server so that the content could be delivered via HTTP/2 in a proper way.

### For Nginx

**Requirements**

Version: 1.9.5 or later (if you have an earlier version, please upgrade).

Setup:

Open `/etc/nginx/nginx.conf` and replace the line in the "Server" section

```
listen 443 ssl;
```

with

```
listen 443 ssl http2;
```

Save changes and restart Nginx with the command:

```
$ sudo service nginx reload  
```

### For Apache

**Requirements**

Version: 2.4.17 or later (if you have an earlier version, please upgrade).

Setup:

Enable the [mod\_http2](https://httpd.apache.org/docs/2.4/mod/mod_http2.html) module (it also can be called mod\_h2\_module).

Add these lines to the configuration file

```
# for a https server  
Protocols h2 http/1.1
```

```
# for a http server  
Protocols h2c http/1.1
```

Restart Apache.

## Benefits of HTTP/2 for CDN

There is no need to create several CNAME records using HTTP/2. One TCP connection is set up and the load goes through it. There will not be any latency due to several simultaneous connections.
