← Lessons

quiz vs the machine

Silver1100

Networking

The Subnets and Route Tables

Slicing a VPC and deciding where packets go.

4 min read · intro · beat Silver to climb

Dividing the VPC

A VPC is one big address range, but you rarely use it as a single block. A subnet is a smaller slice of that range placed in one availability zone. You group resources into subnets so you can control placement and reach.

Public and Private

Subnets get their character from their routes, not from a flag.

  • A public subnet has a route to the internet gateway.
  • A private subnet has no direct internet route.
  • Each subnet lives in one availability zone, so spreading across zones adds resilience.

Route Tables Decide

A route table is a list of rules that says where to send a packet based on its destination. Every subnet is associated with exactly one route table. A local route handles traffic inside the VPC, and you add other entries for gateways.

Key idea

Subnets slice a VPC across availability zones, and route tables decide where each packet goes, with a subnet counting as public only when its route table points to an internet gateway.

Check yourself

Answer to earn rating on the learn ladder.

1. What makes a subnet public?

2. How many route tables is a subnet associated with at a time?