Static routes

Static routes are manually added to a routing table through direct configuration. Using a static route, a router can learn about a route to a remote network that is not directly attached to one of its interfaces. Note that, however, static routes are not widely used today, since you have to configure each static route manually on each router in the network.

Static routes are configured in the global configuration mode using the ip route DESTINATION_NETWORK SUBNET_MASK NEXT_HOP_IP_ADDRESS command. The NEXT_HOP_IP_ADDRESS parameter is the IP address of the next-hop router that will receive packets and forward them to the remote network. The router with the next-hop IP address must be on a directly connected network.

Consider the following example:

static routes example

Let’s take a look at the routing table on R1:

static routes 1

Note that R1 knows about the two directly connected networks: and What it doesn’t know about, however, is the network directly attached to R2. Let’s try to ping a host in that network:

static routes ping fails

The ping command fails because R1 doesn’t know where to send the packets. However, we can specify a static route that will rectify this problem:

ip route command

With the command above, we’ve instructed R1 to send all packets destined for the network to the IP address of (the IP address of the Fa0/1 interface on R2). Let’s try to ping that same host again:

static routes ping successful

Because R1 now knows where to send packets, the ping command is successful.


We could have also specified the exit interface of the local router (R1) instead of the next-hop IP address in the ip route command. In our example, the command would be ip route Fa0/1.
Geek University 2021