Network Flow
Last updated Aug 24, 2026 allows you to keep Magic Transit disabled during normal operations and activate it only when you need DDoS protection. Network Flow monitors your traffic while Magic Transit is off and detects attacks. When an attack is detected, you can enable Magic Transit automatically or manually.
You can create Network Flow rules that monitor specific IP prefixes for DDoS attacks. When an attack is detected, Cloudflare notifies you by email, webhook, or PagerDuty.
If you enable auto-advertisement on a rule, Magic Transit activates automatically to protect the targeted prefixes. You can enable auto-advertisement for individual Network Flow rules through the dashboard or API.
After Magic Transit activates and your traffic flows through Cloudflare, Cloudflare blocks malicious DDoS traffic. Your origin servers receive only clean traffic through IPsec or GRE tunnels.
The following diagrams illustrate this process:



Activate IP auto-advertisement
Before a rule can automatically activate Magic Transit, you must enable IP advertisement for the relevant prefixes. You can do this through the dashboard or the API.
Dashboard
To activate IP advertisement through the Cloudflare dashboard, refer to Configure dynamic advertisement.
API
To activate IP advertisement through the API, refer to the IP Address Management Dynamic Advertisement API.
Network Flow rules
To create Network Flow rules with auto-advertisement, refer to Rule Auto-Advertisement.
Was this helpful?
YesNo
On this page
{"@context":"https://schema.org","@type":"TechArticle","@id":"https://developers.cloudflare.com/magic-transit/network-flow/#page","headline":"Network Flow","description":"Monitor Magic Transit traffic with Network Flow.","url":"https://developers.cloudflare.com/magic-transit/network-flow/","inLanguage":"en","image":"https://developers.cloudflare.com/magic-transit/network-flow/og.png?v=04137915c9a76009","dateModified":"2026-08-24","publisher":{"@type":"Organization","name":"Cloudflare","description":"One platform for your apps, agents, and workforce. Build, secure, and scale without managing infrastructure","url":"https://www.cloudflare.com/","sameAs":["https://github.com/cloudflare","https://www.linkedin.com/company/cloudflare","https://x.com/cloudflare"],"logo":{"@type":"ImageObject","url":"https://developers.cloudflare.com/logo.svg"},"address":{"@type":"PostalAddress","streetAddress":"101 Townsend St","addressLocality":"San Francisco","addressRegion":"CA","postalCode":"94107","addressCountry":"US"},"contactPoint":[{"@type":"ContactPoint","contactType":"Customer Support","url":"https://support.cloudflare.com/","availableLanguage":["English"]},{"@type":"ContactPoint","contactType":"Sales","url":"https://www.cloudflare.com/contact/","availableLanguage":["English"]}]},"isPartOf":{"@type":"WebSite","@id":"https://developers.cloudflare.com/#website","name":"Cloudflare Docs","url":"https://developers.cloudflare.com/"}}
description: Cloudflare IP addresses used by Magic Transit. title: Cloudflare IPs image: https://developers.cloudflare.com/magic-transit/cloudflare-ips/og.png?v=ca003487c3f876bf
Documentation Index
Fetch the complete documentation index at: https://developers.cloudflare.com/magic-transit/llms.txt
Use this file to discover all available pages before exploring further.
