Notepad is one of the simplest text editors in Windows, but it’s surprisingly powerful when it comes to saving files in different formats. Most people only use it for .txt
files, but Notepad can also create and edit other types of text-based files — including HTML, CSV, and more.
If you’ve ever wondered how to save files in formats other than .txt
, or what each format actually means, this guide will walk you through everything step-by-step.
Why Save in Different Formats?
By default, Notepad saves files as plain text (.txt
). However, you can manually choose other extensions based on your purpose.
Here’s why saving in different formats is helpful:
- .TXT → For plain notes or general writing.
- .HTML → For web pages or simple coding projects.
- .CSV → For data that you want to open in Excel or Google Sheets.
- .BAT / .INI / .LOG / .JS → For scripting, configuration, or logs.
This flexibility makes Notepad a useful lightweight tool for writers, students, developers, and data professionals alike.
The Default Format: .TXT Files
When you open Notepad and start typing, it automatically assumes you’re creating a text document.
To save it:
- Click File → Save As.
- In the Save as type dropdown, choose All Files.
- In the File name box, type your name followed by
.txt
(for example,notes.txt
). - Choose a location and click Save.
✅ Pro Tip: If you don’t add “.txt” manually, Notepad will automatically add it for you.
.TXT files are universal — they can be opened on any device (Windows, Mac, Android, iOS) using any text editor.
How to Save as .HTML (for Web Pages)
Want to create a simple webpage? Notepad is actually one of the easiest ways to write basic HTML.
Steps to Save as HTML:
- Open Notepad.
- Type your HTML code, for example:
<!DOCTYPE html> <html> <head> <title>My First Page</title> </head> <body> <h1>Welcome to My Website</h1> <p>This page was created using Notepad!</p> </body> </html>
- Click File → Save As.
- In Save as type, choose All Files.
- In File name, type
index.html
. - Change Encoding to UTF-8 (to avoid text display issues).
- Click Save.
Now go to the folder, double-click index.html
, and it will open in your default web browser! 🌍
✅ Pro Tip:
If you plan to build small web projects, using Notepad++ can make it easier with color highlighting and live formatting.
How to Save as .CSV (Comma-Separated Values)
A CSV file is used for storing data in rows and columns — just like Excel — but in plain text format.
Example CSV content in Notepad:
Name, Age, Country
Ali, 25, Pakistan
John, 30, USA
Emma, 28, UK
💾 Steps to Save as CSV:
- Open Notepad.
- Type your data as shown above, separating each column with a comma.
- Click File → Save As.
- In File name, type
data.csv
. - In Save as type, select All Files.
- Set Encoding to UTF-8 (especially if your data contains special characters).
- Click Save.
Now you can open data.csv
in Microsoft Excel, Google Sheets, or LibreOffice Calc, and it will display in neat rows and columns automatically.
✅ Tip: Always use commas (,
) between columns and new lines between rows.
Understanding the “Save as Type” Option
When you open File → Save As, you’ll see the “Save as type” dropdown. By default, it says:
“Text Documents (*.txt)”
But if you change it to:
“All Files (.)”
…it allows you to save with any file extension.
For example:
index.html
→ Creates a web file.data.csv
→ Creates a data file.script.js
→ Creates a JavaScript file.config.ini
→ Creates a configuration file.
Note: Always type the extension manually if you select “All Files.” Otherwise, Windows may add .txt
automatically at the end (like index.html.txt
).
How to View or Change File Extensions
Sometimes Windows hides file extensions, which can confuse new users.
To fix this:
On Windows 10 / 11:
- Open File Explorer.
- Go to the top View tab.
- Check the box labeled File name extensions.
Now you’ll see the full name like notes.txt
or index.html
— not just “notes” or “index”.
This is important when you’re saving files in custom formats.
Examples of Other File Formats You Can Create in Notepad
Besides .txt
, .html
, and .csv
, here are more file types you can save directly from Notepad:
Extension | Purpose | Example File Name |
---|---|---|
.bat | Batch file (for command automation) | backup.bat |
.ini | Configuration settings | appsettings.ini |
.log | Log file (for recording system events) | errors.log |
.xml | Structured data storage | data.xml |
.js | JavaScript script file | app.js |
.json | Data exchange format (used in APIs) | users.json |
Each of these formats uses plain text but has specific rules for structure.
✅ Pro Tip: You can even use Notepad to write Python scripts — just save them as .py
.
Common Mistakes When Saving Files in Different Formats
Here are a few things users often do wrong — and how to fix them:
Issue | Cause | Solution |
---|---|---|
File shows as index.html.txt | Forgot to choose “All Files” | Re-save with All Files and proper extension. |
File opens as plain text instead of browser | Saved incorrectly | Ensure file type is .html and encoding is UTF-8. |
Special characters not displaying properly | Wrong encoding | Use UTF-8 encoding during save. |
Excel not recognizing CSV columns | Used semicolons instead of commas | Use commas (, ) only, unless your region settings differ. |
Changing File Encoding (Important Tip)
When saving files, you’ll see a dropdown called Encoding at the bottom of the Save window.
You can choose:
- ANSI: Basic English characters (default for older systems).
- UTF-8: Supports all languages and symbols.
- Unicode: Similar to UTF-8, but uses more bytes.
For most modern tasks — especially .html
, .csv
, or .json
— always select UTF-8.
This ensures your text displays correctly on all platforms.
Bonus: Open Different Formats in Notepad
You can open any plain-text-based file with Notepad, even if it’s not .txt
.
For example, right-click any file → Open With → Notepad
You can view code, logs, and data from:
.html
.css
.xml
.ini
.json
.bat
.csv
This makes Notepad a great universal viewer for technical and non-technical users alike.
Final Thoughts
Notepad might seem basic, but it’s a hidden gem for quick file editing and creating multiple text-based file types.
By learning how to save files in different formats, you can:
- Build basic web pages (
.html
) - Manage data for spreadsheets (
.csv
) - Write logs or configuration files (
.log
,.ini
) - Keep clean text notes (
.txt
)
Once you get comfortable using the “Save As → All Files” method and setting proper encoding, you’ll find Notepad to be a simple yet versatile tool for almost any text-based task.
So next time you open Notepad, remember — it’s more than just a place for quick notes. It’s your lightweight workspace for HTML, CSV, and much more.