Home› Blog› GCP Architecture Series #84 — Dynamic Routing Mode: Regional Versus Global…
GCP Architecture GCP Architecture Series

GCP Architecture Series #84 — Dynamic Routing Mode: Regional Versus Global

Dynamic routing mode reads like a reachability switch: regional means a hybrid link serves its own region, global means it serves everything. That is the inbound half. The setting is bidirectional — it equally decides which of your subnet routes are advertised outward to the peer — and it expresses regional distance as an addition to MED whose values are per region pair and unpublished. It also governs every Cloud Router in the network at once while not reaching policy-based or route-based VPN tunnels at all.

Verified against current vendor documentation on 5 November 2026. Pricing, limits and API behaviour were checked against the official docs on that date. Cloud services change fast — if you are reading this much later, treat the specifics as a starting point and re-check the linked sources.

Business Challenge

#83 deferred to this setting three times, which is a fair measure of how much rests on it. The definitions are short. Regional dynamic routing mode: each region's dynamic route control plane only processes learned routes from the Cloud Router BGP tasks in its own region, and consequently the resulting dynamic routes created in a particular region of a VPC network have next hops only within that specific region. Global adds one step — each region's dynamic route control plane also sends the best path for each prefix to the dynamic route control planes in all other regions used in the VPC network — so the resulting dynamic routes created in a particular region of a VPC network can have next hops in any region.

Read that way it is a reachability switch, and that reading is half the setting. Three things make it more than that.

1
"Switching to global just lets our other regions reach on-premises"

It also changes what you tell the peer about yourself. The dynamic routing mode of a VPC network controls which subnet routes its Cloud Routers advertise. In regional mode, each BGP session that advertises subnet ranges only sends the subnet ranges that are in the same region as the Cloud Router that contains the BGP session. In global mode, each BGP session that advertises subnet ranges sends both the subnet ranges that are in the same region as the Cloud Router that contains the BGP session and subnet ranges in other regions.

Correct approach

Count the prefixes you will advertise before flipping the switch, and tell whoever runs the peer router. A network with subnets in eight regions goes from advertising one region's ranges per session to advertising all of them, on every session. If the peer enforces a maximum-prefix limit, the session it drops is the one you were trying to fix.

2
"We will set it on the Cloud Router for that link"

There is no such setting. Each VPC network has an associated dynamic routing mode that controls the behavior of all of its Cloud Routers, stated again in the VPN documentation as the dynamic routing mode of your VPC network controls the behavior of all its Cloud Routers. One value, network-wide, applying to every hybrid attachment you have.

Correct approach

Treat it as a network-level architectural decision, not a per-link tuning knob. If one link needs global behaviour and another must stay regional, the mechanism is not this setting — it is separate VPC networks, or route filtering on the sessions you want narrowed.

3
"We changed the mode and nothing happened"

Check what kind of tunnel you have. The dynamic routing mode of a VPC network only affects the behavior of Cloud Routers. And explicitly: it does not affect Cloud VPN policy-based or route-based tunnels. Those carry static routes, not dynamic ones, so a network-wide change to dynamic routing touches nothing about them.

Correct approach

Establish which of your tunnels use BGP before attributing anything to this setting. An estate on Classic VPN with policy-based tunnels can have its dynamic routing mode flipped back and forth with no observable effect at all, which is a confusing place to start debugging.

Architecture

One value on the network, acting on both directions, implemented as arithmetic on MED.

Diagram: how dynamic routing mode is a single per-network setting that governs every Cloud Router in the VPC network and acts in both directions at once, deciding both which learned routes reach which regions and which subnet routes are advertised outward; the regional mode where each region processes only its own BGP tasks so dynamic routes have next hops within that region alone; the global mode where each region also publishes its lowest-MED best path to every other region and an inter-regional cost unique to each region pair is added to the MED, with the own-region cost being zero; the two control planes where the dynamic route control plane selects and truncates before the VPC control plane may still suppress a candidate; and the scope limit that the mode governs Cloud Routers only and not policy-based or route-based VPN tunnels
One network-wide switch, acting in both directions, expressing regional distance as MED.

Distance becomes a number added to MED

This is the part worth understanding properly, because it is how global mode avoids being merely "everything reaches everything". On the advertising side the two cases are precise. For same-region ranges, the advertised MED matches the configured base priority of the BGP session. For distant ones, the advertised MED of subnet ranges in different regions is the sum of the configured base priority of the BGP session and an inter-regional cost.

So your peer receives your whole network's subnets with your local ones looking cheapest, and it will prefer them if it honours MED. Global mode does not flatten geography; it publishes geography as a metric.

The same arithmetic runs inbound. When a region receives best paths from elsewhere, when adding each next hop, the dynamic route control plane adjusts the MED value by adding an inter-regional cost, and each adjusted MED value is the sum of the original MED value plus an inter-regional cost. The scale is anchored at home: next hops in the dynamic route control plane's own region have an inter-regional cost of 0.

The cost is per region pair, and you cannot look it up

Next hops learned from dynamic route control planes in other regions have nonzero inter-regional costs, unique to each region pair consisting of the sending region and receiving region. Not one constant, not a per-region value — a value for each ordered pair, and the documentation gives none of them. The practical consequence is that you can predict the ordering (local beats remote, and nearer presumably beats further) but you cannot compute a MED that deliberately competes with a remote path across a specific region pair. If you need a particular path chosen, set the base priority on the session rather than trying to out-arithmetic a number you cannot see.

There is a decisive filter in global mode that makes local paths win outright rather than merely rank better: when the dynamic routing mode of the VPC network is global, the dynamic route control plane removes from consideration all next hops except for the next hops that have the smallest inter-regional cost. Since the own-region cost is zero, any locally learned next hop eliminates every remote one before MED comparison even matters. Global mode therefore behaves like regional mode whenever a local path exists, and only reaches across regions when it does not — which is exactly the failover behaviour people want, achieved without a failover mechanism.

One exemption is worth remembering because it is a useful lever: the dynamic routing mode has no effect on the advertised MED for custom IP address ranges. Custom ranges always advertise at the session's base priority, wherever their addresses nominally live. If you want a prefix advertised at a predictable metric regardless of mode, a custom range is the way to get it. The matching trap: a custom IP address range is ignored if it exactly matches a subnet route that a Cloud Router advertises according to the dynamic routing mode of its VPC network — so in global mode a custom entry duplicating any region's subnet does nothing, where in regional mode the same entry for a distant region's subnet would have worked.

Two control planes, two places a route can vanish

#83 established the shape: both types of Cloud Router learned routes are processed by a dynamic route control plane and then a VPC network control plane. The mode operates in the first, and the second gets a veto.

Between regions, only the best survives: the dynamic route control plane sends only the next hops that have the lowest MED value to the dynamic route control planes in other regions, though ties are preserved — if more than one next hop has the same lowest MED value, then they're all exported to the dynamic route control planes in other regions. So a second-best path in one region is not merely deprioritised elsewhere; it is never offered.

Downward, the winners are defined precisely: the dynamic route control plane sends all next hops with the highest rank and smallest inter-regional cost to the VPC control plane, and these dynamic routes have Andromeda route priority 65536. But the hand-off is lossy and the documentation is careful to promise little: the dynamic route control plane only guarantees that it sends the routes with the lowest MED values to the VPC control plane. Higher-MED routes may arrive and may not. When they do, they are visibly second-class — but they use lower Andromeda route priorities—for example, 65537 , 65538.

Then the final filter, which has nothing to do with regions: each region's VPC control plane receives candidate dynamic routes from the region's dynamic route control plane, and evaluation results in either creating a dynamic route in the VPC network that contains the Cloud Routers or suppression of the candidate dynamic route. The commonest reason for suppression is a collision you may not have considered — the candidate dynamic route destination prefix conflicts with a local, peering, or NCC subnet route.

What this means for debugging

"The route is not in my routing table" has at least four distinct causes here, and they need checking in order. The peer never advertised it. The dynamic route control plane in that region never received it, because regional mode confines processing to the region's own BGP tasks. It received it but did not forward it, because it was not a lowest-MED path or lost the smallest-inter-regional-cost filter. Or it reached the VPC control plane and was suppressed by a conflicting subnet route. Only the first is a peer problem, and it is the only one most runbooks check.

Why This Architecture Holds Up

The mode belongs to one network, but its effects do not stop at that network's edge — and where they land is not always intuitive.

Across a peering, the exporter decides: when using VPC Network Peering, the dynamic routing mode of the VPC network that exports custom routes controls how dynamic routes are created in peer VPC networks that import custom routes. So if you import custom routes from a peer, the regionality of what you receive is set by their configuration, not yours. Combined with #81 — where custom route export and import are separate flags held by separate administrators — a hybrid path through a peer depends on three decisions in two projects, one of which is this mode.

For NCC the ownership is likewise elsewhere: NCC dynamic routes apply to one region or all regions of the VPC network according to the dynamic routing mode of the VPC network that contains the hybrid spoke. The spoke's network decides, not the workload network receiving the routes. After #82, where a VPC spoke has no import filter at all, this is the second respect in which a spoke inherits a routing decision made by somebody else's network.

Within your own network the applicability rule is stated plainly in the routes documentation: dynamic routes can apply to VM instances, VLAN attachments, and Cloud VPN tunnels in either the region containing the dynamic route's next hop or all regions, based on the dynamic routing mode of the VPC network. And the creation rule names both settings together, which is the right mental model after #83: dynamic routes are created in one region or in all regions based on the dynamic routing mode and best path selection mode of the VPC network that contains the Cloud Router. Mode decides how far; best path selection decides which.

Two things neither mode changes

The first is the ceiling, and it is the most important sentence to carry out of both posts: dynamic routes always have a lower VPC network route priority compared to static routes. Global mode buys reach and it buys failover. It does not buy precedence. A static route for the same destination wins in either mode, so if a hybrid path is being ignored, the mode is not the thing to change.

That is not a policy layered on top — it is arithmetic, and knowing the numbers makes it memorable. The best dynamic routes land at priority 65536, and the 65536 priority number is purposefully chosen because it's one value larger than 65535, which is the lowest a static route can hold. One off the bottom of the static range, by construction, so if both static and dynamic routes exist for the same destination prefix, a static route is preferred by the routing order. There is no priority you can set on a BGP session, and no mode, that reaches above 65535. Lower-ranked dynamic routes sit further down still, at 65537 and beyond.

The second is withdrawal, which is the property that makes dynamic routing worth the complexity at all: if a next hop for a dynamic route becomes inaccessible, the Cloud Router that manages its BGP session instructs the VPC network to remove the dynamic route. That holds in both modes, and in global mode it is what turns the inter-regional cost filter into real failover — the local zero-cost next hop disappears, and the remote ones that were filtered out become eligible.

For completeness, the MED comparison behaviour from #83 interacts with the inter-regional cost through one configuration value. With it enabled, the dynamic route control plane uses adjusted MED values when repeating the Consider neighbor ASN step; with it off or unset, the dynamic route control plane repeats the Consider neighbor ASN step using original MED values. Whether regional distance participates in the neighbour-ASN comparison is therefore itself a choice, which is one more reason the arithmetic here is not worth trying to predict precisely.

Choosing, in practice

The honest summary is that global is usually right and regional is occasionally necessary. Global gives cross-region reachability over a single hybrid link, automatic failover with no failover configuration, and a MED scale that already prefers local paths. Regional gives a smaller advertised prefix set, strict regional blast radius, and a routing table that is easier to reason about per region.

The cases where regional genuinely wins are narrower than they look: a peer that cannot accept your full prefix count, a regulatory requirement that one region's traffic not egress through another, or an estate where each region has its own hybrid link and you want a failure to stay local rather than silently reroute across the backbone and change the latency profile without telling anybody. That last one is the real argument for regional, and it is an operational preference rather than a technical limit.

Key Architecture Decisions

Situation Decision Because
One hybrid link serving several regions Global Regional confines dynamic routes to next hops in their own region.
Before switching to global Count the prefixes each session will advertise, and warn the peer Every session begins advertising all regions' subnet ranges, not just its own.
A peer enforcing a maximum-prefix limit Stay regional, or advertise custom ranges instead The outbound half of the setting is what will trip the limit.
One link needs global, another must stay regional Separate VPC networks, or filter on the session The mode is one value for every Cloud Router in the network.
Changing the mode produced no effect Check whether the tunnels are policy-based or route-based The mode affects Cloud Routers only, not those tunnel types.
Wanting cross-region failover Global, and nothing else Local zero-cost next hops win until they are withdrawn, then remote ones become eligible.
Wanting a predictable advertised metric Advertise a custom range The mode has no effect on the advertised MED of custom ranges.
A custom range that appears to do nothing in global mode Check whether it duplicates any region's subnet route An exact match against an advertised subnet route is ignored.
Trying to make a remote path win Set the session's base priority; do not compute against the cost Inter-regional costs are per region pair and unpublished.
A learned route missing from the table Check all four stages, not just the peer It can be lost at the peer, in regional confinement, in truncation, or in suppression.
A hybrid route learned but not used Look for a static route, not the mode Dynamic routes always rank below static routes, in either mode.
Importing custom routes from a peer Ask what mode their network uses The exporting network's mode controls how the routes are created in yours.
Receiving routes through an NCC hybrid spoke Check the spoke network's mode, not your own NCC dynamic routes follow the mode of the network containing the hybrid spoke.
Needing a regional failure to stay regional Regional, deliberately Global will reroute across the backbone and change the latency profile silently.

The one to look at today

For each VPC network with a Cloud Router, read the dynamic routing mode and then count how many subnet ranges each BGP session is advertising. If the mode is global and the network spans several regions, that count is the number of prefixes you are pushing at every peer, and it grows every time anyone adds a subnet anywhere — #83 established that subnet advertisements update automatically. Then ask whoever operates the peer router what their prefix limit is. Those two numbers are the thing most likely to break, and neither is visible from your own console.

Closing Thought

The misreading worth correcting is that this is a reachability setting. It is a scope setting, and scope has two directions. Half the documentation describes what your VMs can reach and half describes what your peer is told, and the two halves are in different pages — the learned-routes page and the advertised-routes page — which is exactly why the outbound half is the one that surprises people. Nothing in the console says "this will also change what you advertise".

The mechanism underneath is more elegant than the switch suggests. Rather than a mode that toggles reachability on and off, Google expresses geography as a number added to MED, anchors it at zero for your own region, and then filters on smallest cost before comparing anything else. The result is that global mode behaves identically to regional mode while a local path exists and only differs when one does not. That is a failover feature implemented entirely as arithmetic, with no failover logic anywhere — and twenty-four posts in, it is the most quietly well-designed thing I have found in this block.

Next in this series

#85 reaches the product all of this has been serving: Cloud VPN, Classic versus HA VPN — and the one of the two that still cannot use any of the dynamic routing described here.

Comments

How was your experience?
Your feedback helps improve this site.
PoorExcellent