Custom Domains vs Routes

I already read the documentation, especially this part (https://developers.cloudflare.com/workers/configuration/routing/#what-is-best-for-me)
What is best for me?
It's recommended to run production Workers on a Workers route or custom domain, rather than on your workers.dev subdomain. Your workers.dev subdomain is treated as a Free website ↗ and is intended for personal or hobby projects that aren't business-critical.

Custom Domains are recommended for use cases where your Worker is your application's origin server. Custom Domains can also be invoked within the same zone via fetch(), unlike Routes.

Routes are recommended for use cases where your application's origin server is external to Cloudflare. Note that Routes cannot be the target of a same-zone fetch() call.
What is best for me?
It's recommended to run production Workers on a Workers route or custom domain, rather than on your workers.dev subdomain. Your workers.dev subdomain is treated as a Free website ↗ and is intended for personal or hobby projects that aren't business-critical.

Custom Domains are recommended for use cases where your Worker is your application's origin server. Custom Domains can also be invoked within the same zone via fetch(), unlike Routes.

Routes are recommended for use cases where your application's origin server is external to Cloudflare. Note that Routes cannot be the target of a same-zone fetch() call.
But I'm still not sure what is the appropriate solution for my use case. My cloudflare workers is made from hono + bun, which contain route handler (GET + POST) to fetch 3rd party api.
Cloudflare Docs
Routes and domains · Cloudflare Workers docs
Connect your Worker to an external endpoint (via Routes, Custom Domains or a workers.dev subdomain) such that it can be accessed by the Internet.
1 Reply
James
James3w ago
Are you running anything else on the domain/subdomain you want to run your Worker? If yes, Routes are probably more appropriate If no, Custom Domain should be fine

Did you find this page helpful?