# Send X-Forwarded-For in TCP Mode

**URL:** <https://discourse.haproxy.org/t/send-x-forwarded-for-in-tcp-mode/877>\
**Category:** Help!\
**Created:** [December 22, 2016, 4:13pm UTC](https://discourse.haproxy.org/t/send-x-forwarded-for-in-tcp-mode/877 "2016-12-22T16:13:18Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![mrafael](https://avatars.discourse-cdn.com/v4/letter/m/a9adbd/32.png) [@mrafael](https://discourse.haproxy.org/u/mrafael)\
**Post date:** [December 22, 2016, 4:13pm UTC](https://discourse.haproxy.org/t/send-x-forwarded-for-in-tcp-mode/877/1 "2016-12-22T16:13:18Z")

</div>

Hi there!

I am new to this discourse.

Can someone tell me how to set up a frontend/backend configuration, in TCP Mode that sends always the header X-Forwarded-For.

I want to balance 2 Cisco WSA web proxies in port 8080.

Thanks in advance

---

<div class="post-metadata">

**Author:** ![lukastribus](https://avatars.discourse-cdn.com/v4/letter/l/7ea924/32.png) [@lukastribus](https://discourse.haproxy.org/u/lukastribus)\
**Post date:** [December 22, 2016, 8:49pm UTC](https://discourse.haproxy.org/t/send-x-forwarded-for-in-tcp-mode/877/2 "2016-12-22T20:49:50Z")

</div>

You have to use HTTP mode for that. When you use HTTP mode, you enable it with the “option forwardfor” directive.  
[https://cbonte.github.io/haproxy-dconv/1.6/configuration.html#4-option%20forwardfor](https://cbonte.github.io/haproxy-dconv/1.6/configuration.html#4-option%20forwardfor)
