How to Enable WiFi on Kali Linux

How to Enable WiFi in Kali Linux

To connect to the Internet and access the public network, one of the most common methods is to connect to WiFi, in different environments installed on popular Linux distributions, the way to activate WiFi is different. WiFi can be enabled and disabled both through the desktop environment and through the command line in popular Linux distributions. Most famous Linux distributions have GNOME and KDE desktop environments by default, also applying specific settings in graphical environments is naturally easier than making changes in the terminal environment, and you can easily enable and disable WiFi in graphical environments.

Activating WiFi using the command line is not too difficult, and by the way, in some Linux distributions, it is very simple to apply settings in the graphical user interface. Especially since today scripts are programmed to enable and disable WiFi to make it easier for Linux users to change their settings.

In this article, for your guidance, we will teach you how to enable and disable WiFi in Kali Linux, one of the modern and attractive Linux distributions, you have already familiarized yourself with Kali Linux, through the desktop environment and the command line. So you can freely use the method that is easier for you to apply your changes. If you want to enable or disable WiFi on Kali Linux, follow the instructions below.

prerequisite

Kali Linux is an excellent distribution in that we have presented how to install Kali Linux in previous tutorials. In this article, we are going to teach how to “turn on WiFi” in Kali Linux and how to disable it. If you plan to use Kali Linux on the server and access the Internet via WiFi, buy Linux VPS with btc will provide you with this possibility.

Therefore, one of the prerequisites for executing the instructions that we will teach later is a system or server with the Kali Linux operating system. Additionally, you must have root user privileges and log into the Linux system using the Sudo command.

Enable and disable WiFi in Kali Linux via GUI

How to connect to WiFi in KDE, GNOME, and Xfce desktop environments are almost similar to each other. Follow the steps below to enable or disable WiFi in the Kali Linux desktop environment.

First, find the network icon in the Taskbar, which is located on the right side and at the top of the screen next to the clock icon.

Enable and disable WiFi in Kali Linux via GUI

 

Then, by right-clicking on the Network icon, if you want to connect to WiFi, select “Enable Wi-Fi” among the options.

If you want to disable the WiFi connection, check the Disable WiFi option.

Enable and disable WiFi in Kali Linux via GUI

After the WiFi adapter is activated, single-click on the Network icon and select the WiFi you want to connect from among the available WiFi networks.

By selecting the desired WiFi network, a window will open asking for the password to connect to the WiFi network. After entering the password, click on the “connect” button to complete the process. Then, by clicking on the Network icon, you will have access to the WiFi network and the Internet.

To view connection details, after connecting to WiFi, right-click on the Network icon from the menu of the Network icon, select “Connection Information” and view information about the WiFi network and your connections.

Enable and disable WiFi Networking in Kali Linux through the terminal

You can use different commands to connect to the desired WiFi in Kali Linux. We will teach different methods about connect to wifi in kali using command line.

  • Connect to WiFi network through iwlist

The first step to connect to a network in the terminal environment is to scan and identify available networks. Running the iwlist command can help you in this regard:

iwlist wlan0 scan

 

Enable and disable WiFi in Kali Linux via command

Available networks are displayed in the output, to connect to the desired network, you can use the grep command to get a more useful output and connect to the desired network more easily. In this tutorial, we are going to access the ESSID (Extended Service Set Identifier) network, for this reason, use the following command to provide the output of ESSID networks:

iwlist wlan0 scan | grep ESSID

Enable and disable WiFi in Kali Linux via command

After you identify the networks and access the network you want to connect to, you can connect to it using various commands.

1. Connect Kali Linux to WiFi via nmcli command

To control NetworkManager and connect to the network, using the nmcli command is a simple and practical method. To run the nmcli command, you need to enter the network name and password in the following format:

nmcli d wifi connect [The desired network name ] password [The desired network password]

By executing the above command, you will be connected to the desired network. If you need help about the nmcli command, you can refer to its man page .

2. Connect to WiFi in Kali Linux via nmtui command

The nmtui command, like the nmcli command, provides the ability to control NetworkManager. To connect to the desired WiFi network, type the following command:

nmtui

After running the above command, the menu you see in the image below will be displayed for you, you must select the “Activate a connection” option using the keyboard and then press the Enter button.

Enable and disable WiFi in Kali Linux via command

In the menu that will be displayed again, you will see the available networks, select the desired option using the keyboard and then press Enter.

To connect, it is enough to have access to the Internet in advance, and finally, you must now have access to the WiFi network you want.

After connecting to the desired network, select the Back option and then press Enter.

Enable and disable WiFi in Kali Linux via command

To exit the nmtui command prompt, select Quit and press Enter.

Enable and disable WiFi in Kali Linux via command

  • Connect to the WiFi network through the ip command

Another way to connect to a WiFi network is to use the ip command. To access the desired WiFi adapter name and connection details (if you were already connected to a network), enter the following command in the terminal environment:

$ ip a

If you want to disable your WiFi connection, run the following command:

$ sudo ip link set dev [name of desired WiFi ] down

Also, to enable WiFi by Backupping your desired adapter run the following command:

$ sudo ip link set dev [name of desired WiFi ] up

You can run theip a command again to check the WiFi connection.

Troubleshooting command for when Wifi device drivers are not detected

In Kali Linux, this problem is not common, but if you encounter this issue, you can use the following command to troubleshoot:

sudo apt install kali-linux-wireless

Of course, this problem may be related to the failure of your wireless card, so it is better to identify your network device name first so that you can make the necessary settings:

iwconfig

After identifying the name of your network device, run the following command:

ifconfig [wireless card name ] up

How to Enable WiFi adapter in Kali Linux

Disabling Wifi Adapter may be one of the reasons why you cannot see the wireless device and available networks in the list. To enable the Wifi Adapter in Kali Linux, enter the Kali Linux terminal environment and execute the following command:

sudo ifconfig wlan0 up

By running the previous command, you should access a list of available networks, otherwise, it is better to restart the Kali Linux operating system.

The WiFi adapter is used when connecting to the WiFi network, so in the same way, we explained earlier, you must enable the Kali Linux Wifi and enter the password of the Wifi network and connect to the desired network. It should be noted that usually when Kali Linux is used in virtual environments, not recognizing the wireless adapter is one of the common concerns that using an external adapter can solve your problem.

Of course, if executing the command we provided and restarting the Kali Linux system does not affect activating your WiFi adapter, consider using an external adapter as one of the solutions. Although the use of Kali Linux in virtual environments does not require a wireless adapter, if you are using a physical system, enabling the wireless adapter can be an important factor in improving WiFi performance.

Why is Kali Linux Enable WiFi not showing

One of the problems that Kali Linux users may face is the failure to show Enable WiFi in Kali Linux. This problem arises based on different software and hardware configuration of users’ systems, but some solutions can solve this problem.

To solve this problem, while the Kali Linux system uses the internal WiFi adapter, you need to identify the driver that the adapter uses. For this purpose, enter the following command:

lspci -nnk | grep -iA2 net

By running the previous command, you will get complete information about the network adapters on your Kali Linux system. After knowing the desired adapter, you must run themodprobecommand to load the desired driver.

For example, if the ath9k_htc drive is used for the adapter, the command you must run to load the desired drive will be as follows:

modprobe ath9k_htc

After executing the previous command, your problem should be solved and you can access a list of enabled WiFi networks. If your problem is not solved, you can solve your problem by installing the firmware-Atheros package, which provides firmware for Atheros-based wireless adapters.

FAQ

Nmcli is a command that allows you to control NetworkManager and provides information about the network status, so run the following command to scan WiFi networks:

nmcli dev wifi

Conclusion

In this article, you learned how to connect to a WiFi wireless network through the graphical environment and the command line of your Kali Linux operating system. The advantage of Linux is that it offers users different methods to apply settings, you can use both the graphical method, which is a simple method for the desired settings and the command line method to connect to WiFi.

Learning the command line method can be useful for you in different situations, especially in this tutorial, this method for connecting to WiFi is similar in most Linux distributions. Also, by connecting to WiFi using the terminal environment, you can easily troubleshoot and solve problems such as lack of connection. Usually, the command line method can work better on servers.

Thank you for choosing our article to read.

Leave a Reply

Your email address will not be published. Required fields are marked.