Nmtui is a powerful tool that can be used to configure and manage Linux Wi-Fi networks. This article will show you how to use Nmtui to configure your network, as well as some tips for using Nmtui. If you’re new to Linux, or if you’re just looking for a way to improve your networking skills, Nmtui is a great tool to start with. With Nmtui, you can easily configure your network settings, including your Wi-Fi connection. To get started with Nmtui, open the application by typing nmtui in the terminal window. You’ll see the main window of Nmtui displayed. In this window, you’ll need to first identify your network card and device name. To do this, click on the “Network” tab and select “Network Cards.” Then, under “Device Names,” select the card name that corresponds to your computer’s hardware. Next, under “Connection Type,” select “Wi-Fi.” Finally, under “Status,” click on the link that says “Show Details.” This will display detailed information about your current Wi-Fi connection. Once you have identified your network card and device name in NMTUI, you’ll need to enter your wireless security key into the application. To do this, click on the “Security” tab and select “Wireless Security.” Then enter your security key into the appropriate field. You can also enable or disable encryption on your wireless connection by clicking on the link that says “Encryption Status.” Now that you have identified your network card and device name in NMTUI and entered your wireless security key, it’s time to configure your Wi-Fi connection settings. To do this, click on the link that says “Wi-Fi Connection Settings.” In this window, you’ll need to specify which network you want to connect to (your home or work network), as well as which encryption protocol (W ..
Nmtui is short for Network Manager Text User Interface. It presents a curses-based TUI containing interactive prompts. Whereas nmcli commands can be complex and tricky to remember, a single nmtui invocation drops you into a set of menus that help you configure your connections.
Main Menu
Running nmtui with no arguments displays a menu of three options. Use your arrow keys to highlight an item, then press enter to select it.
Edit a connection – This sub-menu provides options to add, edit, and delete known connections. Activate a connection – This screen shows the Wi-Fi networks you’re within range of and lets you open a connection. Set system hostname – Displays a popup prompt that lets you edit your machine’s hostname. This change will take effect across your system.
You can jump straight to one of these menus by supplying nmtui an appropriate argument:
nmtui edit or nmtui-edit– Show the edit screen. nmtui connect or nmtui-connect – Show the connections screen. nmtui hostname or nmtui-hostname – Launch the hostname editing prompt.
You can get out of the menu by highlighting the “Quit” option or pressing Esc. When you’ve traveled down through multiple screens, keep pressing Esc to navigate back up and eventually leave the program.
Connecting to a Network
Connections are enabled via the “Activate a connection” screen. You’ll see a list of all the nearby Wi-Fi networks, including a bar graph indication of signal strength.
Use the up and down arrow keys to select the network you want to join. Either press Enter or tab across to the “Activate” button to complete the connection. You’ll be prompted to enter the network’s password if it has protection.
One limitation of the connection screen is the absence of a “scan for available networks” button. The list does refresh periodically but it can take up to a minute to present a network you’ve just come within range of.
You can use nmtui’s CLI-based counterpart, nmcli, to force an immediate rescan. Drop out of nmtui and run nmcli rescan in your terminal. Run nmtui connect again to launch back into the graphical network selection screen which should now be refreshed with up-to-date options.
Nmtui’s activation screen also lets you disconnect from networks. Scroll to your connection in the list and hit Enter to go offline. You don’t need to manually deactivate if you’re switching to another network: find the new one in the list and press Enter to connect in one step.
Viewing Saved Connections
The “Edit a connection” menu lists all the Wi-Fi networks known to your device. Select a connection for editing by highlighting it with the arrow keys, pressing Tab to get to the right sidebar menu, and then highlighting the “Edit…” option. Press Enter to display the connection’s details.
Use the form to adjust your network’s properties. The “profile name” field at the top changes the network’s display name within Nmtui. This is independent of the Wi-Fi SSID which is set two fields down. It’s followed by a “Password” field so you can apply any Wi-Fi password changes you’ve made on your router.
The following sections, IPv4 Configuration and IPv6 Configuration, give you advanced control over network access and routing. Use the arrow keys to highlight the “Show” button, then press Enter to access these sections. You’ll see new fields that let you assign a static IP address, set a gateway IP, and customize your DNS servers.
Checkboxes at the bottom of the screen control the network’s availability. Clear the “Automatically connect” field to stop your device using the network whenever it’s in range. This is ideal for infrequently used or potentially insecure networks. The “available to all users” checkbox controls whether other Linux user accounts can access this network using your stored credentials.
Once you’re done with your edits, use the arrow keys to reach the Cancel and OK buttons at the bottom of the form. Tab across to “OK” and press Enter to save.
Nmtui’s list of stored connections also lets you add new networks without connecting to them first. Select the “Add” link in the right sidebar, above the “Edit…” button used above, to get a blank connection details form that lets you fill out the SSID and password to save. Known networks can be deleted by selecting them in the list, tabbing across to the right sidebar, and using the arrow keys to highlight “Delete”.
Summary
Nmtui is a simple interface to NetworkManager, the system daemon responsible for initializing and maintaining network connections. Nmtui lets you take control of your networks without leaving your terminal or learning long command strings. You can activate connections, edit their properties, and remove them from your system using Nmtui’s interactive menus.
While we’ve focused on Wi-Fi connections in this article, Nmtui is also compatible with wired and virtual networking devices. You’ll see these at the bottom of the “Edit a connection” menu. Selecting any of the connections will let you edit its IP addresses and DNS settings.
For more advanced control, you’ll need to look behind the scenes and use nmcli directly. This command-line tool exposes all the capabilities of NetworkManager, including hardware controls for your system’s network devices.
You can get detailed guidance on using both Nmtui and Nmcli by reading their respective manual pages. man nmtui and man nmcli contain instructive information on the available commands and flags.