Starter Guide

Configure WiFi and Bluetooth on PI

Configuring Raspberry Pi  : Wifi and Bluetooth

The latest model of PI i.e. Raspberry Pi 3 comes with built in wireless connectivity over WiFi and Bluetooth, BLE. Here, we will go through the steps for setting up your Pi  WiFi via GUI and terminal command window, and connecting a Bluetooth device like a speaker to play audio. The steps will be similar for both the previous versions of Raspberry Pi (PI 2 and Model B+ , which requires USB Dongles for Wi-Fi and Bluetooth Connectivity.

Setting up Wi-Fi via the Graphical User Interface

Before starting, kindly make sure that you have the latest version of Raspbian OS or any third party updated OS running on Raspberry Pi. If, you are confused about OS Installation then you can also follow the steps provided in our ‘Raspberry Pi : Crash Course’ blog  to complete the installation.  Once, you have the latest version of the OS installed on your PI hardware then follow the steps, as given here:

Step 1:  Go to the top most right corner of your home screen (desktop) and click on the network icon to see the list of available networks. From there you can see all the available networks in the vicinity of the Pi.

Step 2: From the drop down list select the desired WiFi SSID (network’s name).

Step 3: A dialogue box will appear that will ask you Wi-Fi password, type it into the text box and click Ok. That’s all, you are connect to the Wi-Fi network. You should now see your network’s signal strength displayed in the upper task bar on the right corner.

Setting up Wi-Fi via the Command Line Interface

You can follow this method, if you don’t have access to the GUI that is if you don’t have a monitor or display screen connected with Pi and you are using serial console cable to command the Pi. No additional software is required for this; everything is already included on the standard Raspberry Pi image.


Step 1:First, you have to scan for local wireless networks using the command

sudo iwlist wlan0 scan


This will list all available Wi-Fi networks with all sorts of other useful information like its IP address, Ports, etc.

Step 2: From the list find your Network’s Name(SSID); which will be listed next to ESSID.

Step 3: Under the ESSID you should also see your authentication method, which could look like the following IEEE 804.11i/WPA2 Version 2. As in this case, the authentication method is WPA2, which is the newer and more secure method; these steps will work with both WPA and WPA2 type of security

Step 4: Now you need to add your Wi-Fi settings to the wpa-supplicant configuration file. Type the following in the command line to the configuration file:

sudo nano /etc/wpa_supplicant/wpa_supplicant.conf


Go to the bottom of the file and add the following Wi-Fi setting, adding your setting in the quotation marks.



Save the file by pressing CTRL+X and then Y on the keyboard and press enter to confirm. At this point, the wpa-supplicant configuration file will normally notice within a few seconds

when a change has occurred and it will try to connect to the Wi-Fi network. If the Wi-Fi does not connect then a reboot maybe required with sudo reboot . Once your Wi-Fi has connected successfully you can verify it by typing ifconfig wlan0; if the inet addr field has an IP address in it then it has successfully connected.


Note: Type help in the command line, and you can find the commands related to the Bluetooth such as paired-devices, pair, scan and other.

Also, Bluetooth can be accessed in the same way through GUI as Wi-Fi, previously.





Show More

Related Articles

Leave a Reply

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

Back to top button