What happens if a client's request passes through multiple Cloudflare edge servers?

Question

Grade: Education Subject: Support
What happens if a client's request passes through multiple Cloudflare edge servers?
Asked by:
83 Viewed 83 Answers

Answer (83)

Best Answer
(407)
When a request passes through multiple Cloudflare edge servers, the `X-Forwarded-For` header will contain a comma-separated list of IP addresses, starting with the original client IP and followed by the IP addresses of each edge server it passes through. `set_real_ip_from` will only consider the *first* IP address in the `X-Forwarded-For` header as the client's IP address. This is the intended behavior.