To start writing HTML, you only need a simple text editor. HTML files are plain text files — any program that can save plain text can be used to write HTML.
An HTML editor is a software application for creating web pages. It allows you to write and edit HTML code. There are two main types:
You can write HTML using the simplest text editor — Notepad. Here is how:
On Windows, open Notepad by searching for it in the Start menu.
Type the following HTML in Notepad:
<!DOCTYPE html>
<html>
<head>
<title>My First Page</title>
</head>
<body>
<h1>Hello World!</h1>
<p>This is my first HTML page.</p>
</body>
</html>
Save the file with a .html extension:
index.htmlFind your saved file, right-click it, and choose Open with → Browser. Your page will display in the browser!
On Mac, you can use TextEdit to write HTML:
index.htmlFor a much better coding experience, professionals use dedicated code editors. These editors offer:
| Editor | Platform | Best For | Free? |
|---|---|---|---|
| VS Code | Windows, Mac, Linux | Everyone — Most popular | Free |
| Sublime Text | Windows, Mac, Linux | Fast & lightweight coding | ✅ Free (paid license optional) |
| Notepad++ | Windows only | Beginners on Windows | Free |
| Atom | Windows, Mac, Linux | Customizable editor | Free |
| Brackets | Windows, Mac, Linux | Front-end web design | Free |
For beginners and professionals alike, VS Code is the most recommended HTML editor in the world. Here is why:
You can also write and test HTML directly in your browser using online editors — no installation needed:
codepen.iojsfiddle.netw3schools.com/tryit