Home › HTML Tutorial › HTML installation
HTML installation
Full step-by-step installation for Windows, macOS and Linux.
Step 1: Install a code editor
- Open
code.visualstudio.comand click the Download button for your system. - Windows: run the installer, accept the agreement and tick Add to PATH and Open with Code. macOS: open the downloaded zip and drag Visual Studio Code into the Applications folder. Linux: run
sudo snap install code --classicor install the .deb file. - Open VS Code once to make sure it starts.
Step 2: Create your first file
- Create a new folder, for example
my-site. - In VS Code choose File, then Open Folder, and select it.
- Create a new file named
index.html. - Paste the code from the editor below and save it (Ctrl+S, or Cmd+S on macOS).
Step 3: Open it in the browser
- Find
index.htmlin your folder and double-click it. - The page opens in your browser. After every change, save the file and press F5 to refresh.
Optional: live reload
Install the Live Server extension in VS Code, right-click index.html and choose Open with Live Server. The page then refreshes by itself when you save.
If something goes wrong
- The file opens as plain text: make sure its name ends with
.html, not.html.txt. - Changes do not show: save the file and refresh the browser.
Example code
<!DOCTYPE html>
<html>
<body>
<h1>HTML is working</h1>
</body>
</html>