How to Connect to WiFi in Kali Linux: A Complete Guide

operating system Kali Linux Kali is traditionally associated with professional pentesting and security auditing, but like any other system, it requires access to the global network to function properly. Newcomers who have just installed the distribution often encounter the lack of a graphical interface for selecting wireless networks, which can be confusing. Unlike traditional desktop installations, the barebones version of Kali may require manual configuration of network interfaces via the command line.

In this article, we'll cover all the current methods for activating a wireless module. We'll look at how to use the standard NetworkManager through a graphical interface, as well as more advanced methods through a console with a utility nmcliUnderstanding these processes is critical, as a stable connection is the first step to running network scans or updating repositories.

It's worth noting that the methods may vary depending on the desktop environment you're using, whether it's Xfce, GNOME or KDEHowever, the basic principles of how network daemons work remain the same. We will also touch on driver issues, as some Wi-Fi adapters require the installation of proprietary modules for correct operation.

Checking adapter compatibility and status

Before attempting to enter the network password, you need to ensure that the operating system even "sees" your wireless device. In the Linux world, and especially in penetration testing distributions, hardware support depends on the kernel and installed drivers. It's common for the adapter to be detected by the system but turned off or running in monitor mode, which isn't intended for regular surfing.

For primary diagnostics, a utility is used ip, which replaced the outdated one ifconfigBy entering the command ip link in the terminal, you will get a list of all network interfaces. Wireless devices are usually referred to as wlan0, wlp2s0 or similar variations containing the prefix "wl". If instead you see only eth0 or lo, perhaps the driver for your card is not installed or the device is physically disconnected.

📊 Have you encountered driver problems in Linux?
Yes, I'm constantly looking for drivers.
No, everything works out of the box.
I only use a virtual machine
I work only with cable

Pay special attention to the interface status. If there is a label next to the interface name in the command output NO-CARRIER or state DOWN, this means the interface is not active. In some cases, the adapter may be blocked by software switches. rfkill, which we'll discuss in the next section. It's also important to check if the card is in monitor mode (mode monitor), since in this mode a standard connection to the access point is impossible without switching the mode.

⚠️ Important: If you're using an external USB adapter for Kali Linux, make sure it's connected directly to your computer's port and not through a USB hub with insufficient power. Insufficient power can cause constant disconnects or the device's failure to be detected by the system.

Managing wireless modules via rfkill

One of the most common reasons why you can't connect to WiFi is a software or hardware blockage of the wireless module. In Linux, a utility is responsible for managing radio modules. rfkillIt allows you to enter a locked state and remove it if necessary. This is especially relevant for laptops, which may have physical WiFi switches or function keys.

To get information about the current status of all wireless devices, run the command:

rfkill list

In the output you will see a list of devices with marks Soft blocked (software blocking) and Hard blocked (hardware lock). If you see yes against Soft blocked, this means that the system has disabled the module programmatically. This can be fixed with the command rfkill unblock wifi or rfkill unblock all to unlock all radio interfaces.

The situation with Hard blocked It's more complicated. If the "yes" light is on, it means the device is physically disabled. This could be a switch on the laptop case, a key combination (for example, F2 or F12 (with an antenna icon) or BIOS/UEFI settings. It's impossible to remove the hardware lock using Kali Linux software; physical interaction with the device is required.

After successful unlocking, repeat the check with the command ip linkThe interface should change its state. If the block is removed but reappears automatically after a few seconds, another energy or network management service may be conflicting, such as ModemManager, which sometimes mistakes WiFi adapters for modems.

Connecting via the NetworkManager graphical interface

For users who prefer visual management, Kali Linux uses the default NetworkManager. In most assemblies with a graphical shell (for example, Xfce) The network applet is located in the upper right corner of the screen. If it displays a crossed-out computer or wire icon, the wireless module is either disabled or not configured.

To initiate a connection, tap the network icon. If WiFi is off, select "Turn On WiFi." The system will begin scanning for available access points. In the list that opens, find your network name (SSID). Clicking it will open a password entry field. Make sure your keyboard layout matches the required one, as case is important.

After entering the security key, the system will attempt to obtain an IP address via DHCP. If successful, the icon will change to a signal strength indicator. If unsuccessful, NetworkManager typically reports the reason as "Authentication failed" (incorrect password) or "Failed to connect" (configuration error). For more detailed diagnostics, you can run a graphical utility. nm-connection-editor, which allows you to create new connection profiles manually, set static IP addresses and DNS servers.

Connection status Possible cause Action
Connecting... (endlessly) DHCP or driver issues Check logs, try a static IP
Authentication failed Incorrect WiFi password Double-check your password and keyboard layout
Secrets were required but not provided Key entry error Re-enter the password in the dialog box
Device not managed NetworkManager does not manage the interface. Check nmcli config or interface settings

Sometimes an interface may be marked as "Unmanaged." This often happens if NetworkManager configuration files explicitly specify to ignore certain devices, or if another service is attempting to manage the network, such as systemd-networkdIn such cases, the graphical interface will not allow you to select a network, and you will have to switch to console methods.

Setting up WiFi via the terminal using nmcli

Console utility nmcli (NetworkManager Command Line Interface) is a powerful network management tool in Kali Linux. It allows you to perform all the same actions as the graphical interface, but with greater granularity and automation capabilities. This is the preferred method for server versions of Kali or when working over SSH.

The first step is always to search for available networks. The command nmcli device wifi list will display a table of all visible access points indicating their SSID, channel, signal speed (Signal) and security type. If the list is empty, make sure the interface is enabled with the command nmcli radio wifi on.

☑️ Checklist for connecting via nmcli

Completed: 0 / 4

To connect directly to the network, the following syntax is used:

nmcli device wifi connect "Network_Name" password "Your_Password"

Instead of Network_Name substitute the SSID of your access point, and instead of Your_Password — security key. Please note that if the network name contains spaces, it must be enclosed in quotation marks. After the command is successfully executed nmcli will create a new connection profile and attempt to activate it. If successful, the terminal will display the message "Connection successfully added and activated."

If you need to connect to a hidden network (one that does not broadcast the SSID), add the flag hidden yes:

nmcli device wifi connect "Hidden_SSID" password "Password" hidden yes

To view all saved connection profiles, use the command nmcli connection showThis is useful if you want to delete an old profile or change its settings, for example, switch from a dynamic IP to a static one. Deleting a profile is done with the command nmcli connection delete"Profile_Name".

Troubleshooting drivers and interfaces

The most challenging step often occurs when the adapter is physically present, but the system cannot find a suitable driver for it. In Kali Linux, based on Debian, most drivers are in the repositories non-freeIf you are using a clean installation, these repositories may not be activated by default due to licensing restrictions.

To install proprietary drivers (for example, for chips Realtek or Broadcom) A temporary internet connection via a USB modem (tethering mode from the phone) or an Ethernet cable is often required. Once network access is established, you need to update your package lists and install the firmware:

sudo apt update

sudo apt install firmware-realtek firmware-brcm80211

What to do if the driver is not in the repositories?

If the standard firmware packages don't help, your adapter may be too new or rare. In this case, you'll need to find the driver source code on GitHub, compile it manually (using the linux-headers kernel headers), and load the module with the modprobe command. This requires knowledge of the make and gcc compilers.

Another common issue is conflicting operating modes. For security audits, monitor mode is often used, which puts the card into a state unsuitable for normal connection. To return to management mode (managed mode), run:

sudo ip link set wlan0 down

sudo iw dev wlan0 set type managed

sudo ip link set wlan0 up

Here wlan0 — this is the name of your interface. After these steps, NetworkManager should start seeing available networks again. If the problem persists, it might be worth checking the kernel logs with the command dmesg | grep firmware or dmesg | grep wlan, which often contain precise indications of the cause of the driver failure.

⚠️ Warning: When manually compiling drivers from source, there is always a risk of system instability after a kernel update. A module compiled for one kernel version may fail to load after an upgrade. It is recommended to use a package manager whenever possible.

Alternative methods and the iwctl utility

In newer versions of Kali Linux, especially in minimalist builds, a daemon may be used instead of the classic NetworkManager iwd (iNet wireless daemon) and management utility iwctlThis is a modern replacement for outdated tools. wpa_supplicant. Interface iwctl more interactive and intuitive for those accustomed to the command line.

To get started, enter iwctl in the terminal. You will be taken to an interactive shell (the prompt will change to [iwd]#). Inside the shell, follow these steps:

  • 📡 device list — show a list of wireless devices.
  • 📡 station wlan0 scan — start scanning networks (replace wlan0 with your interface).
  • 📡 station wlan0 get-networks — show found networks.
  • 📡 station wlan0 connect"SSID" — connect to the network (the system will ask for a password).

After successful connection inside iwctl You can exit the shell with the command quitHowever, in order for the system to automatically obtain an IP address, it is often necessary to start the DHCP client manually if it is not integrated: dhcpcd wlan0 or dhclient wlan0.

Usage iwctl This is especially useful in situations where NetworkManager isn't working correctly or is consuming too many resources. It's a lightweight solution, perfect for quick connections in the terminal. Remember that settings made through iwctl, by default are not saved after reboot unless the corresponding configuration file or service is configured.

Frequently Asked Questions (FAQ)

Why doesn't Kali Linux see my WiFi adapter?

The problem is most likely a missing driver. Check the command output. lsusb (for USB) or lspci (for integrated cards). Find the Vendor ID and Device ID, then search for the corresponding driver in the Debian/Kali repositories or on the manufacturer's website. This often requires installing packages from the non-free section.

How do I switch back to monitor mode after connecting to WiFi?

First, disconnect the interface from the network (for example, via nmcli device disconnect wlan0). Then execute sudo ip link set wlan0 down, sudo iw dev wlan0 set type monitor And sudo ip link set wlan0 upNetworkManager may try to take over control, so sometimes you need to stop it temporarily.

Is it possible to use an external USB WiFi adapter for connection and the built-in one for auditing?

Yes, this is a good practice. The built-in adapter can be left for stable internet access via NetworkManager, and an external one that supports injections can be used in VirtualBox or VMware (by passing a USB device to the guest OS) to work with aircrack-ng.

What should I do if I have a connection, but websites won't open?

Check your DNS settings. Try pinging the IP address (e.g. ping 8.8.8.8). If the ping works, but the domains don't work, enter the DNS servers manually in the connection settings or in a file /etc/resolv.conf (For example, nameserver 8.8.8.8).

How do I save my WiFi password so I don't have to enter it every time?

When using NetworkManager or nmcli Passwords are saved automatically in the system's secure storage after the first successful connection. When using iwctl or wpa_supplicant manually, you need to write the configuration into the corresponding files in /etc/so that it is applied at boot.