Cloudflare Routing to another server region
duvey03
HOBBYOP

a month ago

Project ID: c53050a9-c2eb-41d3-8c2a-0df97e64534d

Hey, routing question on a Hobby service. My app (region us-west) is fronted by a Cloudflare-proxied custom domain. Requests through Cloudflare are landing on your Singapore edge (x-railway-edge: asia-southeast1, x-hikari-trace: hnd1), even though my users + DB are all US/Canada west coast.

When I hit the app directly via a *.up.railway.app domain (bypassing Cloudflare), it correctly routes to a US edge (us-east4). So the trans-Pacific detour only happens on the Cloudflare → origin hop.

It's killing throughput - an ~8 MB POST body takes ~16s just to reach the server (backend compute is ~300ms). Any idea why CF's egress to my service hits the Singapore edge, or how I can get origin traffic onto a US edge? Known issue with Cloudflare-proxied custom domains? 🙏

10 Replies

a month ago

Hello, thank you for the report. We're in the process of moving traffic to new edge subnets/prefixes. Please may I know your domain?


duvey03
HOBBYOP

a month ago

Ahh that would make some sense! The domain is phaseview.ca (and www.phaseview.ca). Both are Cloudflare-proxied (orange-cloud), CNAME'd to c4aj7851.up.railway.app and ujyh59qa.up.railway.app respectively.


a month ago

Got it, thank you. I see the bad route: https://cf-trace.up.railway.app/lax/69.46.46.66

I will try to work to correct this. Cloudflare's network isn't well optimized on the egress path, so they often times pick bad routes. We can't 100% control their network but we can apply traffic engineering on the routes via BGP. I'll get back to you when it's in a better place

Screenshot_2026-06-03_at_04.42.32.png

Attachments


a month ago

Should be fixed, could you let me know?

Screenshot_2026-06-03_at_04.45.35.png

Attachments


duvey03
HOBBYOP

a month ago

Confirmed on my end... x-railway-edge is now us-west2 (lax1) instead of asia-southeast1, and latency dropped right down. Huge improvement, thanks for the quick BGP fix!


a month ago

No problem. Thank you for the report!



Anonymous
PRO

a month ago

I'm having a similar issue with https://api.pntrypal.com (https://pantry-pal-production-f0bb.up.railway.app). Proxied through CloudFlare. The replica is set for US-EAST, however x-railway-edge is europe-west.


I'm having a similar issue with https://api.pntrypal.com (https://pantry-pal-production-f0bb.up.railway.app). Proxied through CloudFlare. The replica is set for US-EAST, however x-railway-edge is europe-west.

Anonymous
PRO

a month ago

Now it's being routed to us-west...


abhimanyurana1995
HOBBY

a month ago

I'm experiencing a similar issue, so I opened a separate thread here. Don't mean to bother the team - I'm just hoping to get this resolved as soon as possible, as it's currently a blocker


Welcome!

Sign in to your Railway account to join the conversation.

Loading...