A default gateway is the router a host sends packets to when the destination is not on the local subnet. Every host needs a default gateway to reach the internet or other networks. If the gateway is unreachable, all off-subnet communication fails – even if the host has a valid IP and DNS.
The default gateway is the next-hop router for traffic destined outside the local subnet. When a host wants to reach an IP not in its subnet (determined by ANDing the destination IP with the subnet mask), it sends the packet to the gateway's MAC address. The gateway then routes the packet toward the destination. In home networks, the default gateway is the ISP router (e.g., 192.168.1.1). In enterprise networks, it is often the VLAN's SVI (Switched Virtual Interface) on a Layer 3 switch. DHCP assigns the default gateway automatically (option 3). Redundant gateways use VRRP (Virtual Router Redundancy Protocol) or HSRP (Hot Standby Router Protocol) to failover if the primary router dies – both present a shared virtual IP that clients use as their gateway.
NAT (Network Address Translation)
NAT translates private IP addresses to public IP addresses at a router boundary. NAT allows many devices to share one public IP. It breaks end-to-end connectivity – inbound connections require port forwarding. Carrier-grade NAT (CGNAT) adds another translation layer, complicating VoIP and gaming.
Subnet
A subnet is a logical division of an IP network defined by a subnet mask (e.g., /24 = 255.255.255.0). Hosts within a subnet communicate directly via ARP without routing. Hosts in different subnets must send traffic through a router. Subnetting reduces broadcast domains and enables hierarchical IP allocation.
Routing Table
A routing table is a data structure in a router or host that maps destination network prefixes to next-hop addresses and interfaces. Longest prefix match determines which route applies. Routes come from static configuration, DHCP (default route), or dynamic protocols (BGP, OSPF). An empty routing table means no connectivity.