What it does
iwconfig shows (and in some cases sets) basic wireless interface attributes such as
ESSID, mode, frequency/channel, transmit power, and power management flags. It’s part of the
wireless-tools suite and predates modern nl80211-based tooling.
How it works (mechanical)
iwconfig talks to the kernel through the older Wireless Extensions (WEXT) API.
Many modern drivers either emulate WEXT partially or ignore write operations, so reads often work
while “set” operations may have limited effect.
- Reads link/quality/bitrate info exposed by WEXT
- Requests basic configuration changes via WEXT ioctls
- Does not manage WPA/WPA2/WPA3 authentication (handled by
wpa_supplicant/NetworkManager) - Cannot access many modern 802.11 features (HT/VHT/HE details, scan richness, regulatory nuance)
10 Practical Examples
# 1) Show all wireless interfaces (summary) iwconfig
# 2) Show details for a specific interface iwconfig wlan0
# 3) Show only interfaces that are wireless (filter out “no wireless extensions”) iwconfig 2>/dev/null | grep -v "no wireless"
# 4) Set ESSID (open network / legacy workflows) sudo iwconfig wlan0 essid "MyNet"
# 5) Set operating mode (managed/ad-hoc/monitor depending on driver) sudo iwconfig wlan0 mode managed
# 6) Set channel (may be ignored on managed connections) sudo iwconfig wlan0 channel 6
# 7) Set frequency (example for 2.437 GHz, channel 6) sudo iwconfig wlan0 freq 2.437G
# 8) Set transmit power (units depend on driver; commonly dBm) sudo iwconfig wlan0 txpower 20
# 9) Toggle power management (useful when chasing intermittent drops) sudo iwconfig wlan0 power off sudo iwconfig wlan0 power on
# 10) Quick “signal sanity” loop (reads) watch -n 1 iwconfig wlan0
Notes & Gotchas
- Many “set” operations are ignored on modern drivers or overridden by NetworkManager.
- WPA/WPA2/WPA3 cannot be configured with
iwconfig; usenmcliorwpa_supplicant. - Channel/frequency changes on a managed interface can disconnect you (or simply be rejected).
- Values like “Link Quality” are driver-specific and not comparable across chipsets.
- If you need real scan + station detail, prefer
iw(nl80211).
Historical Context
iwconfig (wireless-tools) was the standard Linux Wi‑Fi CLI for years, built on Wireless Extensions (WEXT).
As Linux Wi‑Fi moved to mac80211/cfg80211 and the nl80211 interface, iw became the modern replacement.
Today, iwconfig remains useful mainly for quick status reads and older systems.
Modern Equivalent / Related Tools
- iw — modern nl80211 Wi‑Fi control and inspection
- nmcli — manage Wi‑Fi connections via NetworkManager
- ip link — bring interfaces up/down
- wpa_supplicant / wpa_cli — authentication and roaming control
- rfkill — unblock wireless radios