
Routes users to different servers based on their IP address. You tell Route 53: "if a user's IP is in this range, send them to this server."
| Goal | How IP Routing Helps |
|---|---|
| Save money | Route users from expensive ISPs to cheaper endpoints |
| Improve speed | Route users to servers with better network paths to them |
CIDR is just a way to write a block of IPs in shorthand.
203.0.113.0/24 → all IPs from 203.0.113.0 to 203.0.113.255 (256 addresses)
200.5.4.0/24 → all IPs from 200.5.4.0 to 200.5.4.255 (256 addresses)
Think of /24 as one street (256 houses) and /16 as an entire neighborhood (65,536 houses).
A named list of IP ranges and their locations. You create this in Route 53.
CIDR Collection: "my-isps"
Location-1 → 203.0.113.0/24
Location-2 → 200.5.4.0/24
A DNS record that links a location name to an actual server IP.
example.com → 1.2.3.4 (IP-based: location-1)
example.com → 5.6.7.8 (IP-based: location-2)
User A (IP: 203.0.113.56) User B (IP: 200.5.4.100)
│ │
└──────────────┬─────────────────────────┘
▼
Route 53
│
Check CIDR Collection
│
┌──────────────┴──────────────┐
▼ ▼
Matches Location-1 Matches Location-2
(203.0.113.0/24) (200.5.4.0/24)
│ │
▼ ▼
Server 1.2.3.4 Server 5.6.7.8
(New York) (London)
Step 1 — You create a CIDR Collection mapping IP ranges to location names.
Step 2 — You create DNS records linking each location to a server IP.
Step 3 — User visits your site. Route 53 sees their IP.
Step 4 — Route 53 looks up the IP in your CIDR Collection, finds the matching location, and returns the correct server IP.