STP Port States Explained: Blocking to Forwarding

Understand all five classic Spanning Tree port states—disabled, blocking, listening, learning and forwarding—what each port does, how long transitions take and how RSTP differs.

STPIEEE 802.1DSwitchingCCNA
9-part learning path

Spanning Tree Protocol Series

Follow these lessons in order to move from Layer 2 loop prevention through edge-port protection to Rapid PVST+ configuration.

Part 2 of 9
Lesson overview

In This Lesson

Read STP state as a timeline of what the port is allowed to do. Connect BPDU processing, MAC learning, forwarding, timers, and RSTP differences.

  1. What are the STP port states?
  2. STP port states explained
  3. STP port states comparison table
  4. Why classic STP can take 30 or 50 seconds
  5. Verify STP states on a Cisco switch
  6. Watch STP port transitions in real time
  7. Classic STP states vs RSTP states
From idea to operation

Quick Learning Map

Keep these three decisions in view as you work through the detailed lesson.

1

Identify the state

Determine whether the port is blocking, listening, learning, forwarding, or disabled.

2

Interpret behavior

Know whether BPDUs, MAC learning, and user frames are permitted.

3

Connect it to convergence

Use timers and topology events to explain why the state is changing.

Fast orientation

STP Port States Explained: Blocking to Forwarding at a Glance

Use this summary to establish the big picture before moving into commands, examples, and troubleshooting.

Classic STP

Uses blocking, listening, learning, forwarding, and disabled states.

RSTP

Combines non-forwarding behavior into discarding for faster operation.

Troubleshooting clue

A state is meaningful only with the port role and root-path decision.

Spanning Tree Port States learning map
Learning map for Spanning Tree Port States showing the article's core concepts, workflow, practice topics, and troubleshooting path.

What are the STP port states?

The Spanning Tree Protocol determines whether a switch interface can forward user traffic by moving it through several port states. If you plug a cable into a Cisco switch and watch the interface LED change from orange to green, STP is checking the topology before allowing the port to forward frames.

Classic IEEE 802.1D STP uses five states: disabled, blocking, listening, learning and forwarding. A port selected to carry traffic moves through Listening → Learning → Forwarding. A non-designated redundant port remains in Blocking.
BlockingNo forwarding · No MAC learning
Listening15 seconds · BPDUs only
Learning15 seconds · Learns MACs
ForwardingForwards frames · Learns MACs

STP port states explained

1. Blocking state

A blocked port does not forward user frames and does not learn source MAC addresses. It continues to receive and process BPDUs so it can detect a topology change.

  • Prevents a redundant path from forming a Layer 2 loop
  • Does not forward or flood user traffic
  • Does not populate the MAC address table
  • Can later transition toward forwarding

2. Listening state

A port selected as a root port or designated port enters listening. It participates in STP by processing BPDUs, but it still does not forward user frames or learn MAC addresses.

  • Classic default Forward Delay: 15 seconds
  • Confirms the active topology is stable
  • Does not forward data frames
  • Does not learn source MAC addresses

3. Learning state

The switch begins examining source MAC addresses and building its MAC address table. It still does not forward user frames, preventing data traffic from entering the topology too early.

  • Classic default Forward Delay: 15 seconds
  • Learns source MAC addresses
  • Does not forward user data
  • Prepares the port for forwarding

4. Forwarding state

The port is fully active. It forwards Ethernet frames, learns source MAC addresses and continues processing BPDUs to monitor the spanning-tree topology.

  • Forwards user traffic
  • Learns MAC addresses
  • Processes BPDUs
  • Acts as an active root or designated port

What about the disabled state?

A disabled port does not participate in frame forwarding or STP. The interface may be administratively shut down, physically disconnected or otherwise inactive. Disabled is one of the five classic STP states, but it is not part of the normal convergence path to forwarding.

STP port states comparison table

StateForward user frames?Learn MAC addresses?Process BPDUs?Classic default duration
DisabledNoNoNoUntil enabled
BlockingNoNoYesDepends on topology; up to Max Age in a failure scenario
ListeningNoNoYes15 seconds
LearningNoYesYes15 seconds
ForwardingYesYesYesUntil topology or port status changes

Why classic STP can take 30 or 50 seconds

Normal transition: 30 seconds

A newly selected root or designated port normally waits through two Forward Delay periods before carrying user traffic.

Listening15 seconds
Learning15 seconds

Total: 15 + 15 = 30 seconds before the port reaches forwarding.

Failure scenario: commonly cited worst case of 50 seconds

If a previously blocked port must replace a failed path and the change is detected by aging out old BPDU information, classic STP may wait for the default 20-second Max Age before beginning the listening and learning stages.

Max Ageup to 20 seconds
Listening15 seconds
Learning15 seconds

Worst-case example: 20 + 15 + 15 = 50 seconds.

Accuracy note: Blocking is not always a fixed 20-second countdown. Twenty seconds is the default Max Age used in a common indirect-failure scenario. Direct link failures and topology-change mechanisms can be detected differently.

Verify STP states on a Cisco switch

Use show spanning-tree vlan 1 after reconnecting an interface or performing a controlled shutdown and no shutdown. In the output, Role shows the port role and Sts shows its current state.

First: designated port in listening state (LIS)
SW1# show spanning-tree vlan 1

Interface           Role Sts Cost      Prio.Nbr Type
------------------- ---- --- --------- -------- ----------------
Fa0/1               Desg LIS 19        128.4    P2p
After approximately 15 seconds: learning (LRN)
SW1# show spanning-tree vlan 1

Interface           Role Sts Cost      Prio.Nbr Type
------------------- ---- --- --------- -------- ----------------
Fa0/1               Desg LRN 19        128.4    P2p
After another approximately 15 seconds: forwarding (FWD)
SW1# show spanning-tree vlan 1

Interface           Role Sts Cost      Prio.Nbr Type
------------------- ---- --- --------- -------- ----------------
Fa0/1               Desg FWD 19        128.4    P2p

The abbreviations are easy to remember: LIS = listening, LRN = learning and FWD = forwarding.

Watch STP port transitions in real time

In a controlled lab, event debugging shows each state transition as it happens:

SW1# debug spanning-tree events
Spanning Tree event debugging is on

00:14:57: STP: VLAN0001 Fa0/1 -> listening
00:15:12: STP: VLAN0001 Fa0/1 -> learning
00:15:27: STP: VLAN0001 Fa0/1 -> forwarding
Production caution: Debug commands can generate substantial console output. Use them carefully, preferably in a lab or during a controlled maintenance window, and disable debugging afterward with undebug all.

Classic STP states vs RSTP states

The sequence above describes classic IEEE 802.1D STP. Rapid Spanning Tree Protocol uses three operational states and faster transition rules.

Classic STP (802.1D)
  • Disabled
  • Blocking
  • Listening
  • Learning
  • Forwarding
RSTP (802.1w)
  • Discarding
  • Learning
  • Forwarding

RSTP combines the non-forwarding behavior of disabled, blocking and listening into discarding. Port roles and rapid proposal/agreement behavior help RSTP converge much faster than classic STP.

Spanning Tree Port States Frequently Asked Questions

What are the five STP port states?

Disabled, blocking, listening, learning and forwarding are the five classic IEEE 802.1D states.

Which STP states forward frames?

Only the forwarding state forwards user data frames. Listening and learning prevent forwarding while the topology stabilizes.

Which STP states learn MAC addresses?

Learning and forwarding learn source MAC addresses. Blocking and listening do not.

How long is the STP listening state?

The classic default is 15 seconds, controlled by the Forward Delay timer.

How long is the STP learning state?

The classic default is another 15 seconds, also controlled by Forward Delay.

Why is my switch port orange before turning green?

On many switches, an orange or amber LED indicates that STP is preventing forwarding while the port passes through its non-forwarding states. The exact LED meaning varies by switch model.