How to create WiFi Hotspot in Ubuntu

For a long time on Windows, people have been able to use wireless network adapters to share Internet connections with other computers. On Linux, broadcasting a hotspot is not always easy.

Until recently, users had to manually enter the command line, connect adapters, set up IPtables, etc. In newer versions of Ubuntu, you can now easily create splittable connections. Share via hotspots via GUI. This article will show you how to create a WiFi Hotspot on both GUI and Terminal in Ubuntu Linux.

Create WiFi Hotspot

To use an Ubuntu computer as a WiFi Hotspot, you first need to connect it to an external network source. This is because the hotspot function will disable the adapter's ability to listen and connect to active WiFi access points.

The fastest way to do this is to connect your machine to an Ethernet network. To do that, turn off your device's WiFi adapter by clicking the Quick Settings menu in the upper right corner of the screen.

Picture 1 of How to create WiFi Hotspot in Ubuntu

Click the 'WiFi' button at the bottom left of the menu.

Picture 2 of How to create WiFi Hotspot in Ubuntu

Plug in the Ethernet cable and check to see if your computer detects your new wired connection.

Confirm that your wired network is working properly by opening Terminal and pinging an external website:

ping -c 5 maketecheasier.com

To share this wired connection over WiFi, open Ubuntu's quick menu button, then click the gear icon. This will open the device's System Settings window.

Picture 3 of How to create WiFi Hotspot in Ubuntu

Click the Wi-Fi category on the left sidebar of the window, then toggle the WiFi switch to turn the wireless adapter back on.

Select the Turn On Wi-Fi Hotspot button…

Picture 4 of How to create WiFi Hotspot in Ubuntu

This will open a small window where the system will ask you for details about your hotspot. You can provide your own password or leave it blank to use a random password.

Click Turn On to turn on your new WiFi Hotspot.

Picture 5 of How to create WiFi Hotspot in Ubuntu

Check if your wireless adapter is broadcasting the access point properly by connecting a device to it.

Create a WiFi Hotspot using Bluetooth tethering

In addition to Ethernet, you can also share your computer's Internet connection via a Bluetooth connection. This is useful if you want to create a WiFi Hotspot on the go but don't have a phone capable of creating a hotspot.

To get started, open System Settings on your computer, then click the Bluetooth category on the left sidebar of the window.

Picture 6 of How to create WiFi Hotspot in Ubuntu

 

Turn on your Bluetooth adapter by flipping the switch on the window's title bar.

Picture 7 of How to create WiFi Hotspot in Ubuntu

Go to the Settings app on your phone, then turn on your phone's Bluetooth adapter. In Android 13, you can do that by going to Settings -> Connected devices.

Tap the Pair new device option on your phone.

Picture 8 of How to create WiFi Hotspot in Ubuntu

Doing this will show the phone to your computer. Click your smartphone name on Ubuntu's Bluetooth window.

Picture 9 of How to create WiFi Hotspot in Ubuntu

Open Ubuntu's Quick Settings menu, then select Tether. This will automatically establish a Bluetooth connection between your computer and phone.

Picture 10 of How to create WiFi Hotspot in Ubuntu

Check that your Bluetooth connection is working properly by pinging an external website.

ping -c 5 maketecheasier.com

Return to the System Settings window, then click the Wi-Fi category.

Make sure the WiFi toggle is enabled, then click Turn On Wi-Fi Hotspot…

Double check that your hotspot information is correct, then click Turn On to start your WiFi Hotspot in Ubuntu.

Picture 11 of How to create WiFi Hotspot in Ubuntu

Confirm that your new hotspot is working correctly by connecting your device to it and browsing the web.

Create WiFi Hotspot using command line

In addition to broadcasting WiFi hotspots through the Gnome interface, Ubuntu also allows you to create them through the command line. This can be useful in case you are trying to share a network connection without any GUI.

Make sure your system is connected to the Internet through another network interface. This is possible via Ethernet or Bluetooth connection.

Open a new Terminal and check all network interfaces available on your computer:

nmcli d

Find your wireless network interface from the command's output. In the example case, the wireless card is 'wlp0s20f3'.

Picture 12 of How to create WiFi Hotspot in Ubuntu

Run the following command to initialize your WiFi Hotspot:

nmcli con add type wifi ifname wlan0 con-name my-hotspot autoconnect yes ssid MyHotspot mode ap

Configure the access point's internal settings:

nmcli con modify my-hotspot 802-11-wireless.mode ap 802-11-wireless-security.key-mgmt wpa-psk ipv4.method shared 802-11-wireless-security.psk 'YOUR-WIFI-PASSWORD'

Note: Make sure your hotspot password is longer than 8 characters.

Enable and start your new WiFi Hotspot by running the following command:

nmcli con up my-hotspot

Check if your hotspot is working properly by connecting a device through it.

Picture 13 of How to create WiFi Hotspot in Ubuntu

The self-broadcasting wireless access point solution works in a pinch and can help users get out of a difficult situation without a wireless router. That means the router can provide more functionality than your standard wireless adapter.

Update 15 March 2024
Category

System

Mac OS X

Hardware

Game

Tech info

Technology

Science

Life

Application

Electric

Program

Mobile