Categories: LinuxShell

Four Web Browsers for the Linux Command Line

Remember the days when the web was as simple as searchable text. The terminals and low powered personal computers were enough to access the text-based web over snail-paced internet connections. Of course, people then used the command-line web browsers to visit the web; these included the famous Lynx browser as well. Times have changed now, the browser technology has shifted to the graphical and more powerful web-browsers such as Chrome, Firefox and, Safari. Still, there are people who are more Terminal savvy and prefer accessing to-the-point information from the web through Terminal based browsing. Even Terminal based computers also exist and for them, command-line browsers are sometimes the only way to connect to the web. So how do we install and use these text-based browsers through our Linux command-line, the Terminal?

This article gives you four ways to use the web through the Linux Terminal by explaining ways to install and use the Terminal as a web-browser.

We have run the commands and procedures mentioned in this article on an Ubuntu 18.04 LTS system.

If you are already Terminal savvy, you wouldn’t have any problem in opening the Terminal. You can open it through the Dash or by pressing the Ctrl+Alt+T shortcut. You can then install one of the following popular tools in order to browse the internet through the command line:

  • The w3m Tool
  • The Lynx Tool
  • The Links2 Tool
  • The Elinks Tool

The w3m Web Browser

Installation

Enter the following command in the Terminal in order to install the w3m utility:

$ sudo apt-get install w3m w3m-img

Enter Y when the system prompts you to continue installation. The command line browser w3m will be successfully installed to your system.

Verifying the installation

You can verify the installation by checking the version number of w3m as follows:

$ w3m -version

Browsing the Internet

You can browse the Internet through the w3m utility by following this syntax:

Syntax:

$ w3m [URL]

Example:

$ w3m www.google.com

When you enter this command in your Terminal, the output will give you the following display:

You can access a link or move to the search bar simply by double-clicking it. In this example, I have searched for Portugal weather; double-clicking the Google Search link has displayed the search results in the following manner:

Here are some basic operations you can perform on this utility:

Quit the program: Shift+Q

Open a new tab: Shift+T

Open a new URL: Shift+U

Go back one page: Shift+B

The Lynx Web Browser

Installation

Enter the following command as root in the Terminal in order to install the Lynx utility:

$ sudo apt-get install lynx

Enter Y when the system prompts you to continue installation. The command line browser Lynx will be successfully installed on your system.

Verifying the installation

You can verify the installation by checking the version number of Lynx as follows:

$ lynx -version

Browsing the Internet with Lynx

You can browse the Internet through the Lynx utility by following this syntax:

Syntax:

$ Lynx [URL]

Example:

Lynx www.google.com

When you enter this command in your Terminal, the output will give you the following display;

you can use the arrow keys to move to the various links on the page.

In this example, I have tried searching for the weather of New York City. The search results are displayed when I hit return.

The Links2 Web Browser

Installation

Enter the following command in the Terminal as root in order to install the Links2 utility:

$ sudo apt-get install links2

Enter Y when the system prompts you to continue installation. The command line browser Links2 will be successfully installed on your system.

Verifying the installation

You can verify the installation by checking the version number of Links2 as follows:

$ links2 -version

Browsing the Internet

You can browse the Internet through the Links2 utility by following this syntax:

Syntax:

$ links2 [URL]

Example:

$ links2 www.google.com

When you enter this command in your Terminal, the output will give you the following display:

You can access a link or move to the search bar simply by double-clicking it. In this example, I have searched for USA news; double-clicking the Google Search link will display the corresponding search results.

The eLinks Web Browser

Installation

Enter the following command in the Terminal as root in order to install the eLinks utility:

$ sudo apt-get install elinks

Enter Y when the system prompts you to continue installation. The command line browser eLinks will be successfully installed on your system.

Verifying the installation

You can verify the installation by checking the version number of elinks as follows:

$ elinks -version

Browsing the Internet

You can browse the Internet through the eLinks utility by following this syntax:

Syntax:

$ elinks [URL]

Example:

$ elinks www.google.com

When you enter this command in your Terminal, the output will give you the following display:

You can then search for a keyword or string through this search engine.

Note: The terminal emulator Xterm also has the capability to display images in the search results.

Through the four command line tools mentioned in this article, you can easily browse the Internet without using the graphical web browsers on your Ubuntu system. Now you can enjoy faster text-based browsing without worrying about the ads, javascript, and unwanted images. Install whichever browser suits you from the list and enjoy hassle-free Internet browsing!

Karim Buzdar

About the Author: Karim Buzdar holds a degree in telecommunication engineering and holds several sysadmin certifications. As an IT engineer and technical author, he writes for various web sites. You can reach Karim on LinkedIn

Recent Posts

How to Install Magento 2 on AlmaLinux

Magento is a free and open-source e-commerce platform written in PHP. It is simple, easy…

1 year ago

How to Install ISPConfig Hosting Control Panel with Apache Web Server on Ubuntu 24.04

ISPConfig is an open-source control panel that allows users to manage multiple servers from a…

1 year ago

How to Test your Email Server (SMTP) Using the Telnet Command

As a Linux administrator, you may find it necessary to troubleshoot or test your Simple…

1 year ago

Managing Network Interfaces and Settings on Ubuntu 24.04 with nmcli

Ubuntu 24.04, like many modern Linux distributions, relies on the NetworkManager for managing network connections.…

2 years ago

Using Restic Backup on Ubuntu 24.04

Restic is a modern, open-source backup program designed for efficiency, security, and simplicity. It enables…

2 years ago

Installing phpMyAdmin on Rocky Linux 9 and Securing it with Let’s Encrypt SSL

phpMyAdmin is a popular free tool written in PHP intended to administer MySQL and MariaDB…

2 years ago