Under Attack mode adds a browser challenge before eligible requests reach the site. It can help during an active web attack, but it can also interrupt API clients, integrations and legitimate visitors, so apply it with a clear incident scope and exit plan.
IN THIS ARTICLE
What you need before you begin
Confirm traffic is proxied through Cloudflare and collect evidence from security events and origin load. Keep an authorised administrator session and a communication channel available. Identify essential webhooks, APIs and checkout workflows before applying broad challenges.
01 Use Cloudflare Under Attack mode during a web attack
- Open the zone’s Overview and use the Under Attack Mode quick action where available, or the current equivalent security control.
- If the incident is limited to certain paths, consider a supported configuration rule that applies the setting only to those requests.
- Monitor security events, origin health and legitimate user access after enabling it. Check a normal browser session and essential nonbrowser integrations separately.
- Investigate the underlying attack pattern and apply durable, appropriately scoped security controls where needed.
- Disable the temporary mode once the incident has subsided and verify normal access again. Record the timing and effect for future response.
Confirm the expected result
Origin pressure should improve without unacceptable disruption to necessary users and services. A challenge page appearing does not by itself prove the attack is contained.
What if Under Attack mode blocks APIs or payment callbacks?
If APIs or payment callbacks fail, avoid asking them to solve a browser challenge. Refine the scope using supported rules and trusted authentication, rather than broadly allowing all requests. Under Attack mode does not replace origin patching, application security or provider assistance for nonweb attacks.