#Cloudflare pages vs workers

1 messages · Page 1 of 1 (latest)

viral hatch
#

Hello I don't really catch the difference between Cloudflare worker and Cloudflare pages...

Cloudflare pages seems to render static pages where Cloudflare workers is a serverless service (for backend stuff, db, ...).

That said if I'd like to deploy a Sveltkit app it will be on Cloudflare pages if I use it only for my frontend and Cloudflare workers (I don't really know how deploy it... do I need both pages and workers adapters https://kit.svelte.dev/docs/adapters) for a backend + frontend app.

brave mantle
viral hatch
#

So I can build an entire backend service (with auth....) only by using cloudlfare pages ? What the purpose of cloudflare workers then?

peak herald
onyx hollow
#

@peak herald so it sounds like if you're building an API only, you can use workers. But if you're building a full stack app (that'll serve static assets like the js bundle and css), you need to use pages?

Are there any sources I can read about this distinction? Because this was also confusing to me