.txt files
.txt file
Plain Text File
Text with no formatting at all — the format that will still open in fifty years.
What opens a .txt file
- Windows
- Notepad (built in), Visual Studio Code, Notepad++
- macOS
- TextEdit (built in), Visual Studio Code, BBEdit
- Linux
- Text Editor / gedit (built in), Visual Studio Code, nano
- In a browser
- Any web browser
What a .txt file is
A .txt file is just characters, with no fonts, colours or layout, which is exactly why it is the most durable format there is. The only real complication is encoding: a file saved in a legacy code page shows odd symbols where accented letters should be, and UTF-8 is the answer. Line endings differ between Windows and Unix, which is why old Notepad used to show a document as one long line.
Converting it
A .txt file is commonly converted to .pdf, .docx, .csv, .md or .html. It is a plain text format, so any text editor can open and edit it directly.
Details
- Extension
- .txt
- Full name
- Plain Text File
- Category
- Documents
- MIME type
- text/plain
- Created by
- Universal
- Format
- Plain text
Common questions
- How do I open a .txt file?
- On Windows use Notepad (built in); on macOS use TextEdit (built in); on Linux use Text Editor / gedit (built in). Text with no formatting at all — the format that will still open in fifty years.
- What is a .txt file?
- Plain Text File. A .txt file is just characters, with no fonts, colours or layout, which is exactly why it is the most durable format there is. The only real complication is encoding: a file saved in a legacy code page shows odd symbols where accented letters should be, and UTF-8 is the answer.
- Can I convert a .txt file?
- Yes. It is usually converted to .pdf, .docx, .csv, .md or .html, either by exporting from one of the programs listed above or with a format converter.
Related pages
- .pdf — Portable Document Format A fixed-layout document that looks identical everywhere — the format for anythin
- .docx — Word Document (Open XML) The standard Word document since Office 2007 — a zip archive of XML underneath.
- .xlsx — Excel Workbook (Open XML) The standard Excel spreadsheet since 2007, with a million-row limit per sheet.
- .pptx — PowerPoint Presentation (Open XML) The standard PowerPoint deck since 2007.
- .doc — Word Document (legacy binary) The pre-2007 Word format — still readable, but Microsoft would rather you conver
- .xls — Excel Workbook (legacy binary) The pre-2007 Excel format, limited to 65,536 rows.
- .ppt — PowerPoint Presentation (legacy binary) The pre-2007 PowerPoint format.
- .md — Markdown Document Plain text with a light formatting convention — headings with #, bold with **.
- .rtf — Rich Text Format A formatted document format readable by every word processor since 1987.
- .pages — Apple Pages Document Apple's word processor format — Apple devices and iCloud only.
- .odt — OpenDocument Text The open-standard word processor format, native to LibreOffice.
- .eml — Email Message A single saved email, headers and all, in the standard internet message format.
Sources
- Media Types Registry — IANA
- Official vendor product documentation — At One Place