With Cloudflare Access, you can restrict who is authorized to access your application. You decide who is approved, and every request is checked before your Worker runs. Approved visitors are let through, while everyone else is shown a login page or blocked.
You can protect:
- A single application: require sign-in on its preview URLs, production URLs, or both.
- All Workers in your account: protect every existing and newly created Worker by default.
- Specific custom domains and hostnames: restrict access at the hostname or route level.
To use Access with Workers, you need:
- Zero Trust enabled on your account. If Zero Trust is not turned on, complete Zero Trust setup first, then return to the Workers dashboard.
- Permission to manage Workers and Access applications.
| I want to protect... | Section | API destination type |
|---|---|---|
| Preview deployments for all Workers | Protect all Workers | all_preview_workers |
| Production and preview deployments for all Workers | Protect all Workers | all_workers |
| Preview deployments for one Worker | Protect one Worker | preview_worker |
| Production and preview deployments for one Worker | Protect one Worker | worker |