Peering - Why don't I reach the closest datacenter to me?

Why don’t I reach the closest datacenter to me?

Cloudflare is an anycast network, so where you are routed is determined by peering with ISPs. The shortest path geographically isn’t always possible due to peering agreements.

If you request a site hosted on Cloudflare from home:

  • The domain resolves to a Cloudflare IP
  • Your browser sends an HTTP request to that IP
  • Your ISP’s routers consult their routing table and route the packets upstream to their transit provider ( COSTS MONEY )
  • The packets traverse multiple hops to the nearest Cloudflare POP ( TAKES TIME )
  • Those packets are taking up some of the ISPs capacity, making it unavailable for other competing packets ( TRAFFIC MANAGEMENT )

From this blog post

What is Peering?

To address these problems, large networks, hosting providers and CDNs will peer with each other. That is, to interconnect their networks directly. Put another way, cut out the middleman. If I request a site on Cloudflare and my ISP is already directly connected to the Cloudflare network, the packet will traverse fewer hops, my website will load faster, my ISP will pay less to their transit provider and they can allocate that bandwidth for other sites.

From this blog post

You can determine which Cloudflare data center your requests are going to by adding /cdn-cgi/trace to the domain name. E.g. go to in your browser (replacing with your domain name. You will then see colo=ABC with ABC being the airport code of the nearest major international airport to the data center.

Links and resources:

Tool to see where sites are routed based on plan. From fellow MVP, @Judge.

Tutorial Reference: CT-33

Reviewed: 08/21

This is a Community Tutorial, most are wiki posts, so can be contributed to by Regulars and MVPs here. If there is a tutorial you would like to see, you can request one here.

If you would like to provide any feedback on this tutorial, please post in the #Meta category, tag your post #TutorialFeedback and let us know the Tutorial Reference above.

Other great resources on this community include the Community Tips . These address best practices when configuring Cloudflare, how to fix issues you may see, and tools to troubleshoot. Also you can view Expert Tips, great posts on the community from people in the know that may help you with your issue.

We encourage users to check out these great resources and the Cloudflare Support Centre before posting

I want to connect the user to the nearest server
Local POP for free accounts
Privacy location
High IPv6 Latency
Does CF cdn really works for me?
Community Tutorials
Cloudflare not routing through nearest datacentre
WARP+ does not connect to closest Cloudflare POP
Cloudflare wrong routing
Cloudflare is not hosting site from nearest servers, if peoples accessing from india its going to US CDN servers
Cloudflare have VietNam location but my site store in Singapore
How I can choose the location of my server
Getting served by wrong nodes causing high latency
How to change colo to bangkok
Cloudflare dns data center location LUX
Change Colocation-Center in App
Why Website is not severed by closest server-location
I want to connect to the nearest server using cloudflare
High Latency only if pinged through domain resolves to Berlin datacenter
The problem of Data Center is not suitable is using the farest server for my location
Routing when accessing from Bali, Indonesia
Ttfb time increase after using cloudflare
Austria, but colocation PRG since a few days?
My proxied site too slow
CloudFlare PoP Selection & Argo Routing
Cloudflare pulls from Seattle not Vancouver when testing from Vancouver?
Using from Beirut
Getting data from very far away DataCenter
PoP brasil not work not reachable on TATA India network and high latency
Vastly different latency to, Same country
High ping with while 50 on
Quiero que mi pagina estè alojada en mi ciudad
How long does it take to cache a website to my nearest server and update its records?
Specify colo for request
Unable to select Server location
Server and user connection located in HKG, but CDN from SIN
Connecting to the wrong data center (with IPv6)
Data Center
Far away datacenter used
Gcloud server in AUS but Cloudflare in USA (Will it use our local server)
CDN Cities
Cloudflare dns problems
Dns not resolving to closest server
How do I connect to Singapore server?
How to deploy workers and kv to all data centers?
Why is Auckland, NZ, Routing through Osaka, JAPAN?
Colocation center changed
Hi why my cf-ray does not route to the closest data center?
Why Cloudflare won't bring me to the nearest PoP Server?
Why is my site not cached on the CloudFlare network
CDN Nodes for Chinese Users
Cloudflare dns location problem
Can anyone please help me
Can Anyone please help me with this
Issues with Perth Pop
Direct Routing for Transworld Associates
HELP me with my cloudflare! working with high latency in Argentina
AWS CloudFront (Routing Issues)
How to know which data center I'm in?
Sofia Edge server out of service?
Toronto location Bell routing to colo=ORD (Chicago)
Website Traffic from Hong Kong, served by server located in singapore
The location issue
DNS Query returned not accurate location
Wait time of css/js
Wrong Cloudflare Datacenter
Cloudflare WARP MESS
TTFB faster on Pro account vs Free?
Website is not accessible in some areas
Website Latency Increased Since it's on US EDGE Location
Regional Server Issue
Puedo cambiar el país de donde se sirve?
Routing to incorrect continent
Packet forwarding through specific ip addresseses
Requests are not routed through nearest edge servers
Cloudflare server currently at Toyko
CDN location issue
Explicitly set caching to be service from specific region
Data Center Issues
Bad Routes To CloudFlare From My ISP (Only For My Domain)
Tokyo Proxy
DNS does not send my data to the closest data center
Speedtest is not testing with nearest server Resolving distant "CloudFront" servers
Cloudflare nearest datacenter
Cloudflare DNS performs slow on Tamil Nadu, India
German / Austrian endpoints from Hungary
Connecting to LHR from The Netherlands (Should be AMS)
Change cloudflare proxy country
How to test if APO is working
WARP Istanbul End Point Problem
Cloudflare Servers In The Philippines Are Re Routed
Proxied records, I'm getting very far POP for my requests
High Ping with ipv6 Enabled locally for CF enabled site, why
Why am I connected to Djibouti from Cape Town?
Change datacenter loc for website
Tiered Cache, how geographically works?
Over 200ms RTT to Cloudflare IP's from some Australian Carriers (Telstra and Optus)
Peering not properly explained on Cloudflare's Network page
I'm in Toronto, why is my traffic routing through Chicago?
Australian traffic wrong routing
How to connect to Taipei - (TPE) site
My website is pointed to LHR
Limit the countries of сf cdn (edge) servers
WordPress APO not getting access from nearest location
Different CF Domains Route Differently to Same Origin
Do GHA-triggered CFP builds count 2x vs. build limits?
Australian traffic routing on different cloudflare plans
Closest CDN only works for cloudflare domains?
CPH is routing traffic for AS6507 Riot Games, Inc. through Stockholm
Warp routing to Kansas with high ping
My cache is from LAX, but I hope it from TPE
Change Website location to nearest region
Network does not find nearest datacenter
Website not served from closest pop
Routing issues on from Chennai,India
The data center is too far from my location
Can't access many websites with Cloudflare Warp in Turkey
CDN location not right
Not resolving to nearest node
Cloudflare is not hosting site from nearest servers, if peoples accessing from india its going to France CDN servers
Latency on my website
Cloudflare SSL/TLS significantly slows down our server
Cloudflare Data Center not where I live
Peering (posts, resources and links)
WARP connects to a server in another country
Pops united states
Im not routed to the nearest pop routes me to Russia even though I am not in Russia
Cloudflare not connecting to nearest location
I want to go to the Hong Kong node
CF location
Google Cloud accessing API behind Cloudflare is served from farther datacenter over IPv4, but close datacenter over IPv6
Changing the location of the datacenter closer to customers
Free and Pro AU routing
How to change Data Center to #134
Site accessed from Australia forwarding Europe LDNS IP
Routing to wrong coutry .... pages slow
Cloudflare makes APIs super slow - even with Argo enabled
Data Center Location
Pro account + Argo but data is sent from a VERY distant datacenter
Experiencing Cloudflare and Reliance Jio Network issue, Since many days
The negative impact of cloudflare's Israel POP
Cloudflare DataCenter in Buffalo, NY
Proxying requests through Cloudflare increases the latency
For using cloudflare's dns service
Why access from Taipei(Taiwan) can't be routed to Taipei (TPE) nodes?
ISP Metrotel (Buenos Aires - Argentina)
Indonesia POP
Upload files through CF
Help about Colocation needed
I'm getting a far away POP
IPv6 route to slower than IPv4
Tracert from different locations vary to the webserver
Ask about
Wrong POP Location
Traffic not routed through desired Data centre
Website loading slow & High Ping
Connects to the nearest DNS server WARP + Unlimited
Do you have generally available edge servers in Lima, Peru?
Add colocation center selection in WARP
Cloudflare keeps using SIN than NRT
Why is my server in Amsterdam served through CF server in Hamburg?
Traffic from DE is being routed to Paris instead
Routing to Tokyo/Singapore instead of Australia
How to get content served from nearest location