The world of Linux Text editors is very big and cool!
Choosing the right Linux text editor can really boost your productivity when you’re scripting or coding. Whether you’re working on configuration files, writing scripts, or developing software, having the right tool makes everything smoother and more efficient.
In this guide, we’ll go over some of the top Linux text editors, show you how to install them, and explain how to create a new file using editors like Nano, Vim, and Emacs.
Linux Text Editors and Their Importance in Coding & Scripting.
A text editor is a basic software tool that allows users to make quick changes to files. While it is not as advanced as a full word processor, it can still be used to create simple text documents and edit code quickly.
A text editor, also known as a code editor, is specifically made for writing and modifying code in languages like HTML, CSS, JavaScript, PHP, and more.
Many text editors come with features like syntax highlighting, easy navigation, customizable layouts, and options for searching and replacing text.
Get exclusive access to all things tech-savvy, and be the first to receive
the latest updates directly in your inbox.
Linux is a favored operating system for developers and programmers because of its flexibility, customization options, and open-source design. A key tool for developers is a text editor, which helps them write and edit code effectively.
Top Linux Text Editors for Coding & Scripting
1. Nano Text Editor Linux (Best for Beginners)

Nano is a fantastic terminal-based Linux text editor found on Kali Linux. It was created by the GNU project and comes preinstalled on many Linux distributions. It’s user-friendly and, unlike Vim, it doesn’t have different modes.
Another advantage of Nano is that, similar to Vim, it is entirely keyboard-driven and aims to boost developer productivity. However, Nano stands out by displaying basic commands at the bottom of the screen, making it easy for users to perform essential tasks like saving, justifying text, and accessing help. Its simplicity and availability make Nano a great choice for any Linux distribution, from Ubuntu to Kali.
Pros:
- Many Linux distributions come with it already installed.
- It is user-friendly and simple to operate.
- It requires very few system resources.
- It supports GNU Autoconf, has interactive search-and-replace, auto-indent, and spellcheck features.
- Keyboard shortcuts are easy to remember and are shown at the bottom of the editor.
Cons:
- It does not have the advanced features that editors like Vim or Emacs offer.
- Customization options are more limited compared to more powerful editors.
- It has basic syntax highlighting, which might not be enough for developers.
- It is not the best choice for large projects; it works better for smaller tasks.
- Using the keyboard for navigation and editing is slower and less efficient than in more advanced editors.
How to Install Nano on Linux?
Most Linux systems come with the Nano text editor already installed. If it’s not on your system, you can install it using the following commands:
sudo apt install nano # For Debian/Ubuntu<br>sudo yum install nano # For CentOS/RHEL<br>sudo dnf install nano # For Fedora
How to Create a New File in Nano Text Editor?
To create a new file in Nano, use this command:
nano filename.txt
This will open a new empty file for you to start coding or scripting.
2. Vim – The Power User’s Choice
Most Linux distributions, including older ones, come with Vi and Vim editors. Vim, which means Vi Improved, is an enhanced version of the original text editor. Vim is a text editor designed for productivity that works in the terminal. Users can navigate and edit text using only the keyboard and shortcuts, without needing a mouse. It is short for Vi Improved and offers many commands and shortcuts. This makes it lightweight and ideal for pen-testing tasks, as most actions are performed in the terminal.
Here are the advantages and disadvantages of using Vim:

Pros
- Includes keyboard shortcuts and commands for fast text editing.
- Is lightweight and works well on older or less powerful computers.
- Offers many features for editing text, such as macros, multiple buffers, and search and replace.
- Supports plugins and has a built-in tutorial (accessible with the vimtutor command).
- Allows for automatic commands, digraph inputs (helpful in programming), split and session screens, tabs, color schemes (color-coded by function), and tagging.
- Note: Check our guide on Vim color schemes to learn about pre-installed themes and how to install or customize new ones.
Cons
- Needs initial setup and configuration.
- Has a steep learning curve, making it hard for beginners.
- Setting up and managing configurations can be complicated and take time.
- The modal editing system and many commands can be confusing for new users.
Steps to Install Vim on Linux
For Debian/Ubuntu, use:
sudo apt install vim<br>For CentOS/RHEL, use:<br>sudo yum install vim
How to Make a New File in Vim:
Open your terminal and type:
vim filename.txt
When you’re in Vim:
Press i to start typing.
Write your text.
Press Esc, then type :wq to save and leave.
3. Emacs – A Highly Customizable Option

GNU Emacs is a powerful and customizable text editor for Linux users, created by Richard Stallman, the founder of the GNU project. It is versatile and comes with many built-in features.
Emacs is favored by developers for its extensibility and customization options. Although it has a steep learning curve, mastering it can turn it into a very effective tool.
Emacs can be used as both a command-line and a GUI text editor, making it suitable for various users and scenarios. Here are the advantages and disadvantages of Emacs:
Pros:
- Includes content-aware editing modes.
- Offers extensive documentation, tutorials, and language support.
- Highly customizable, allowing significant functionality extensions.
- Provides both command-line and GUI options to meet different user preferences.
- Works well with other GNU applications like organizers, mail apps, calendars, and debuggers.
- Compatible with multiple operating systems, including Linux, macOS, and Windows, ensuring a uniform experience.
Cons:
- It requires considerable setup and configuration to meet specific needs.
- Managing and configuring Emacs can be intricate and time-consuming.
- Emacs tends to use more system resources compared to other text editors.
- The complex interface and extensive features can be overwhelming for beginners.
How to install Emacs on Linux?
To install Emacs on Linux, use these commands:
For Debian/Ubuntu, type:
sudo apt install emacs
For CentOS/RHEL, type:
sudo yum install emacs
To create a new file in Emacs, use this command:
emacs filename.txt
Start typing to edit. To save, press Ctrl + X, then Ctrl + S. To exit, press Ctrl + X, then Ctrl + C.
Other Popular Linux Text Editors
Here are some other very good Linux Text Editors for Developers to use in 2025:
Sublime Text
- Fast, efficient, and easy to use.
- Offers a strong search and replace function.
Atom
- A modern, customizable text editor based on web technologies.
- Has a friendly interface and allows easy plugin creation and installation.
Geany
- A lightweight editor tailored for programmers.
- Includes a robust search and replace feature.
Kate
- A user-friendly editor made for KDE users.
- Comes with a strong search and replace function.
Gedit
- A simple and easy-to-use text editor perfect for beginners.
- Lightweight, making it suitable for older hardware.
Brackets
- A modern editor aimed at web developers.
- Allows easy plugin creation and installation.
Bluefish
- A user-friendly editor featuring a powerful search and replace tool.
Leafpad
- A straightforward editor for basic tasks.
- Lightweight, ideal for quick edits and simple text files.
Joe’s Own Editor (JOE)
- A lightweight and user-friendly editor for newcomers.
Textadept
- A cross-platform editor with a strong search and replace feature.
Jedit
- A cross-platform editor with an easy-to-use interface.
TextMate
- An editor specifically designed for Mac users.
Now, How to Create New File in Linux Text Editors?
Here’s how to create a new file in different Linux text editors:
For Nano:
nano newfile.txt
Start typing and save by pressing Ctrl + X, then Y, and Enter
For Vim:
vim newfile.txt
Hit i to start inserting text, then save by typing :wq.
For Emacs:
<br>emacs newfile.txt
Make your changes and save with Ctrl + X, Ctrl + S.
Using the Terminal (Touch Command):
If you want to create a blank file without opening an editor, use:
touch newfile.txt
After that, you can edit it in your chosen editor.
Final Thoughts on Picking the Right Linux text editor for your workflow
Emacs, Vim, Nano are the best Linux text editor you can pick to streamline your scripting and coding experience. The choice of a Linux text editor really depends on what you need for coding and scripting. Beginners often gravitate towards the Nano text editor Linux, while more experienced users tend to favor the advanced features of Vim or Emacs. If you like a graphical interface, you might enjoy using VS Code or Sublime Text for their modern developer tools.
Now that you’ve got the hang of creating a new file in Linux text editors and exploring different options, which one are you thinking of trying out first?
FAQ’s
1. What’s the top Linux text editor for beginners?
For those just starting out, Nano is the go-to text editor on Linux. It’s super simple, user-friendly, and comes pre-installed on most distributions.
2. How can I create a new file in Linux text editors?
You can create a new file using different text editors in Linux:
Nano: nano newfile.txt
Vim: vim newfile.txt (Hit i to start typing, then :wq to save)
Emacs: emacs newfile.txt
Terminal (without an editor): touch newfile.txt
3. What sets Nano apart from Vim?
Nano text editor Linux offers is straightforward and beginner-friendly, featuring easy shortcuts. On the other hand, Vim is more robust but has a bit of a learning curve with its editing modes.
4. Can I install GUI text editors on Linux?
Absolutely! Besides command-line editors, you can also find GUI text editors for Linux like:
- VS Code
- Sublime Text
- Geany
- Gedit
5. How do I switch between text editors in Linux?
You can have multiple text editors on your Linux system and open files with your preferred one:
- Open a file in Nano: nano filename.txt
- Open with Vim: vim filename.txt
- Open with Emacs: emacs filename.txt
6. Which Linux text editor is best for scripting in Linux?
Vim and Emacs are popular choices for scripting because they offer automation, macros, and better syntax highlighting. However, Nano is great for quick edits to scripts.