Open In App

Text File Format | .txt Extension

Last Updated : 29 Jan, 2024
Improve
Improve
Like Article
Like
Save
Share
Report

TXT file format is the default choice for basic data storage in current-day computing. The reason behind this is that it can be easily created, and edited and is also compatible with most hardware. Therefore, it is widely used for storing data, writing codes, saving logs etc.

What is a TXT file?

TXT file stands for ‘Text File Document’. TXT is a basic text file format that stores plain text and is a widely compatible text format. A TXT file consists of text without complex formatting or styling. Therefore, they are easy to create and edit. Also, avoiding styling makes their file sizes small compared to other file formats. It was developed in the 1960s. Apart from storing basic text information, They are used to store more complex data, such as code and scripts.

Where is TXT used?

TXT files are used for a wide variety of uses, including:

  • Storing simple data
  • Writing codes and scripts
  • System logs
  • Config files
  • Help docs

How to open TXT files?

Opening a TXT file does not require any specialized software. Most operating systems have built-in text editor which can be used to open a TXT file. To open TXT files on Windows, Notepad is used. In Linux, Gedit is used and in Mac, TextEdit is used. All these are built-in text editors of respective Operating systems. The steps to open a TXT file are:

Step 1: Navigate to the location of the TXT file to open in File Manager, then right-click on that TXT file and select ‘Open with’ from the right-click menu.

Screenshot-2023-11-07-105613

Opening the right-click menu and selecting ‘Open with’

Step 2: Selecting ‘Open with’ will open up a menu consisting of several apps. From that menu click on ‘Notepad’ to open a TXT file on Notepad.

Screenshot-2023-11-07-105634

Opening TXT file in Notepad

Step 3: That’s it! Now you can see the contents of the TXT file on Notepad.

Screenshot-2023-11-07-105718

Contents of TXT file

How to create TXT files?

Similar to opening a TXT file, creating a TXT is also done using preinstalled text editors like Notepad (Windows), TextEdit (MAC) and Gedit (Linux). To create a TXT file just open one of this software, type your contents and then save the file. These file editors by default save files as TXT. So, you do not need to change anything just type the contents and save the contents. It will be saved as a TXT file. The steps to create a TXT file are:

Step 1: From the applications list open the Notepad app.

Screenshot-2023-11-07-110415-(1)

Opening Notepad

Step 2: After opening Notepad, type the contents of the TXT file.

Screenshot-2023-11-07-094643m

Typing contents on TXT file

Step 3: After writing the contents of the file, to save the file click on ‘File’ on the top menu bar as shown in figure.

Screenshot-2023-11-07-094643

Clicking File menu

Step 4: Clicking ‘File’ will open a menu consisting list of several options. From that list of options click on ‘Save’. Alternatively, you can also save by pressing Ctrl+S.

Screenshot-2023-11-07-095107

Selecting Save from the File menu

Step 5: Now a popup asking file name will open up. You can see in the popup “Save as type” is by default “.txt”, so no need to change it. Type your desired file name in the ‘File name’ column and click ‘Save’ to save the TXT file.

Screenshot-2023-11-07-115654

Naming and saving TXT file

Now your TXT file is saved successfully!

Applications using TXT files

Many software and operating systems use TXT files to save application logs and system logs. It is also used in many applications to save config files and data. Programmers use it to save their codes and scripts.

Benefits?

Some advantages of TXT files over other text file formats are given below:

  • Small size: TXT files are known to have a small file size compared to other text file formats.
  • Compatibility: TXT is a file format supported by most operating systems.
  • Easiness: It is easy to create and modify a TXT file.

TXT file format is a simple file format used to save text data. It can be created and edited in all operating systems and has a low memory footprint. They are inevitable in the digital world as it is a basic medium of storing data digitally.



Like Article
Suggest improvement
Previous
Next
Share your thoughts in the comments

Similar Reads