Getting your Kali Linux machine online starts with identifying the correct wireless interface. This guide will show you exactly how to connect to wifi on kali linux using both the command line and graphical tools. Whether you are a beginner or a seasoned penetration tester, stable WiFi is essential for your work.
Kali Linux is built for security testing, so wireless connectivity is a core feature. However, it can sometimes be tricky if you don’t know the right commands. We’ll cover everything from checking your hardware to troubleshooting common issues.
Let’s get you connected quickly and reliably.
Checking Your Wireless Hardware
Before you can connect, you need to confirm your wireless adapter is recognized. Kali Linux supports many chipsets, but some require additional drivers.
List Wireless Interfaces
Open a terminal and run this command to see all network interfaces:
iwconfig
This shows wireless interfaces like wlan0, wlan1, or wlp2s0. If you see no wireless interface, your adapter might not be detected. Try:
ip link show
Look for an interface that says “wlan” or “wl”. If nothing appears, your hardware may need a driver update or a USB adapter with better support.
Check If The Interface Is Blocked
Sometimes Kali blocks the wireless interface by default. Use this command to check:
rfkill list
If it shows “Soft blocked: yes”, unblock it with:
rfkill unblock wifi
Now your interface should be ready. You can verify with iwconfig again.
How To Connect To Wifi On Kali Linux Using Command Line
This is the most reliable method, especially for headless systems or when the GUI fails. We’ll use nmcli, the NetworkManager command-line tool.
Step 1: Enable The Wireless Interface
First, bring the interface up:
sudo ip link set wlan0 up
Replace wlan0 with your actual interface name. Check it’s up with:
ip link show wlan0
Step 2: Scan For Available Networks
Scan for WiFi networks:
sudo iw dev wlan0 scan | grep SSID
This lists all nearby network names. Note the exact SSID you want to connect to. If you prefer more detail, use:
sudo nmcli dev wifi list
Step 3: Connect Using Nmcli
Now connect to your network. For a WPA2-PSK network (most common), run:
sudo nmcli dev wifi connect "YourSSID" password "YourPassword"
If the network is hidden, add hidden yes to the command. You should see “Device ‘wlan0’ successfully activated”.
Step 4: Verify The Connection
Check if you have an IP address:
ip addr show wlan0
Also test internet access:
ping -c 4 google.com
If you get replies, you are online. If not, check your password or signal strength.
Connecting To Wifi Using The Graphical Interface
Kali’s desktop environment (usually Xfce) includes a network manager applet. This is easier for beginners.
Locate The Network Icon
Look in the top-right corner of your screen for a network icon (looks like two arrows or a wifi symbol). Click it.
Select Your Network
You’ll see a list of available networks. Click on your SSID. Enter the password when prompted. The system will attempt to connect automatically.
If the icon is missing, you can restart NetworkManager:
sudo systemctl restart NetworkManager
Then try again. This method works well for most users.
Connecting To Enterprise WiFi (WPA2-Enterprise)
Many universities and offices use enterprise networks with username/password authentication. The command-line method differs slightly.
Using Nmcli For Enterprise
First, list available networks:
sudo nmcli dev wifi list
Find your network’s SSID. Then connect with:
sudo nmcli dev wifi connect "YourSSID" --ask
You will be prompted for username and password. Choose the correct authentication type (usually PEAP or TTLS).
Using The GUI For Enterprise
Click the network icon, select your enterprise network. A dialog will appear. Choose “WPA2 Enterprise” as security. Enter your username and password. You may need to set the domain or CA certificate if required.
If you get errors, try disabling certificate validation (not recommended for security but helps for testing).
Using Wpa_Supplicant For Manual Connection
Sometimes NetworkManager fails. The wpa_supplicant tool gives you full control. This is common in penetration testing scenarios.
Generate A Configuration File
Create a file with your network details:
wpa_passphrase "YourSSID" "YourPassword" | sudo tee /etc/wpa_supplicant.conf
This creates a configuration file with your SSID and password hashed.
Connect Manually
Run wpa_supplicant in the background:
sudo wpa_supplicant -B -i wlan0 -c /etc/wpa_supplicant.conf
Then get an IP address via DHCP:
sudo dhclient wlan0
Test with ping. This method is reliable but requires manual steps each time.
Troubleshooting Common WiFi Issues
Even with the right steps, things can go wrong. Here are common problems and fixes.
Wireless Interface Not Found
If iwconfig shows no wireless interface, your driver might be missing. Check with:
lspci -nn | grep -i network
For USB adapters, use lsusb. If you see a device but no driver, install firmware:
sudo apt update && sudo apt install firmware-iwlwifi
Reboot and try again.
Authentication Errors
Double-check your password. WPA2 passwords are case-sensitive. Use the command line to avoid typos. Also, ensure your router supports the security protocol your card uses.
Weak Signal Or Dropping Connection
Move closer to the router. Use iwconfig wlan0 to see signal strength. If it’s low, consider a USB adapter with an external antenna.
You can also change power management settings:
sudo iwconfig wlan0 power off
NetworkManager Conflicts
If you use wpa_supplicant manually, NetworkManager might interfere. Stop it with:
sudo systemctl stop NetworkManager
Then use manual methods. When done, restart NetworkManager.
Using Aircrack-Ng Suite For Monitor Mode
Security testers often need monitor mode for packet capture. This is different from normal connection.
Enable Monitor Mode
First, kill interfering processes:
sudo airmon-ng check kill
Then enable monitor mode:
sudo airmon-ng start wlan0
Your interface will change to wlan0mon. Use iwconfig to verify.
Connect While In Monitor Mode
You cannot connect to a network while in monitor mode. To connect, disable monitor mode first:
sudo airmon-ng stop wlan0mon
Then restart NetworkManager and connect normally.
Connecting To Hidden WiFi Networks
Some networks hide their SSID. You need to specify it manually.
Using Nmcli For Hidden Networks
Run:
sudo nmcli dev wifi connect "YourSSID" password "YourPassword" hidden yes
This tells NetworkManager to scan for the hidden network.
Using Wpa_Supplicant For Hidden Networks
In your wpa_supplicant.conf file, add scan_ssid=1 under the network block:
network={
ssid="YourSSID"
scan_ssid=1
psk="YourPassword"
}
Then connect as before.
Using Ethernet As A Fallback
If WiFi fails, use a wired connection. Plug in an Ethernet cable. Kali should get an IP automatically. Check with ip addr.
You can also share internet from your phone via USB tethering. This is a reliable backup.
Managing Multiple WiFi Profiles
If you switch between networks often, save multiple profiles.
Save A Profile With Nmcli
When you connect, NetworkManager saves the profile automatically. To see saved connections:
nmcli connection show
To connect to a saved profile:
nmcli connection up "YourSSID"
You can also edit profiles with nmcli connection edit.
Using Wicd As An Alternative
If NetworkManager gives you trouble, try Wicd. Install it:
sudo apt install wicd wicd-gtk
Then start it from the menu or terminal. Wicd is lightweight and works well.
Securing Your WiFi Connection
Security is critical, especially on Kali. Avoid open networks. Use VPNs when possible. Also, disable unnecessary services.
Check your firewall:
sudo ufw enable
And keep your system updated:
sudo apt update && sudo apt upgrade
Frequently Asked Questions
Why Does Kali Linux Not Show My WiFi Adapter?
Your adapter might lack drivers. Check with lspci or lsusb. Install firmware packages like firmware-iwlwifi or firmware-realtek. Some adapters require proprietary drivers.
Can I Connect To WiFi Without A Password?
Yes, on open networks. Use sudo nmcli dev wifi connect "SSID" without the password argument. This is not recommended for security reasons.
How Do I Forget A Saved WiFi Network?
Use nmcli connection delete "SSID". This removes the profile. You can also do this via the GUI network manager.
What Is The Difference Between Wlan0 And Wlan0mon?
wlan0 is the standard managed interface for normal connections. wlan0mon is a monitor mode interface used for packet capture. You cannot use both at the same time.
How Do I Fix “No WiFi Adapter Found” In Kali?
Ensure your adapter is plugged in and recognized. Check with lsusb. Install appropriate drivers. Sometimes a kernel update fixes it. Try a live USB with a different kernel version.
Final Tips For Stable WiFi
Keep your system updated. Use a compatible USB adapter if internal hardware fails. Always test your connection after setup. Remember that monitor mode and normal mode are mutually exclusive.
If you follow these steps, you should have reliable WiFi on Kali Linux. Practice the command-line method first, as it gives you more control. The GUI is fine for daily use.
Now you know how to connect to wifi on kali linux. Go ahead and get online.