# How to log if request is HTTP2?

**URL:** https://discourse.haproxy.org/t/how-to-log-if-request-is-http2/2219
**Category:** Help!
**Created:** [March 8, 2018, 9:33pm UTC](https://discourse.haproxy.org/t/how-to-log-if-request-is-http2/2219 "2018-03-08T21:33:52Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![lemkepf](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.haproxy.org/lemkepf/32/432_2.png) [@lemkepf](https://discourse.haproxy.org/u/lemkepf)
#### Post date: [March 8, 2018, 9:33pm UTC](https://discourse.haproxy.org/t/how-to-log-if-request-is-http2/2219/1 "2018-03-08T21:33:52Z")

</div>

Hello,

I’m trying to log if a request is HTTP2 or not. So far I’m not seeing that info with the default “option http-log” settings. I know “ssl\_fc\_alpn” does exist, but can’t figure out for the life of me how to get it into a custom log.

Thanks,  
Paul

---

<div class="post-metadata">

### Author: ![lemkepf](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.haproxy.org/lemkepf/32/432_2.png) [@lemkepf](https://discourse.haproxy.org/u/lemkepf)
#### Post date: [March 8, 2018, 9:42pm UTC](https://discourse.haproxy.org/t/how-to-log-if-request-is-http2/2219/2 "2018-03-08T21:42:00Z")

</div>

Got it! Put “%[ssl\_fc\_alpn]” in your custom log-format.

Example:

```
log-format "%ci:%cp [%tr] %ft %b/%s %TR/%Tw/%Tc/%Tr/%Ta %ST %B %CC %CS %tsc %ac/%fc/%bc/%sc/%rc %sq/%bq %hr %hs %{+Q}r %[ssl_fc_alpn]"
```
