The simplest way to start: use HTML in a text editor
A web page is a text file written in a language called HTML that a browser knows how to read and display. You do not need special software — you can write one in Notepad (on Windows) or TextEdit (on Mac), save it with a .html extension instead of .txt, and open it in any browser. The browser will show you what the page looks like.
Start by opening your text editor and typing this exact code:
<!DOCTYPE html> <html> <head> <title>My First Page</title> </head> <body> <h1>Hello World</h1> <p>This is my first web page.</p> </body> </html>
Save this file as index.html on your desktop. Then double-click it. Your browser will open and show you a page with a large heading that says "Hello World" and text below it. That is a working web page. Everything else you build will follow this same pattern: write HTML tags, save the file, open it in a browser to see the result.
Key Takeaways
- A web page is a text file written in HTML that you can create in any text editor like Notepad or TextEdit.
- Every HTML page needs a basic structure: a DOCTYPE declaration, html tags, a head section with a title, and a body section with your content.
- Save your file with a .html extension and open it in a browser to see how it looks — no server or special tools required.
- Add content using HTML tags like <h1> for headings, <p> for paragraphs, and <a> for links to other pages.
- CSS files control how your page looks (colors, spacing, fonts), and you link to them from inside your HTML file's head section.
Understanding the HTML tags that structure a page
Every HTML tag is a pair of instructions wrapped in angle brackets. The opening tag tells the browser "start doing this thing," and the closing tag (with a forward slash) tells it "stop." Everything between them is what the tag affects.
The tags you will use most are: <h1> through <h6> for headings (h1 is largest, h6 is smallest), <p> for paragraphs of text, <a> to create links to other pages, <img> to show pictures, and <ul> or <ol> to make lists. Here is what a paragraph with a link looks like:
<p>Visit <a href="https://example.com">this website</a> to learn more.</p>
The href part (called an attribute) tells the browser where the link goes. When someone clicks the words "this website," they will be taken to example.com. You can link to other pages you created, or to pages anywhere on the internet.
Adding style with CSS to control how your page looks
HTML structures your content, but CSS controls the appearance — colors, fonts, spacing, and layout. You can write CSS in the same file as your HTML, inside a <style> tag in the head section, or in a separate file that you link to.
Here is a straightforward example. Add this to the head section of your page, between <title> and </head>:
<style> body { background-color: lightblue; } h1 { color: darkblue; font-size: 48px; } p { font-size: 18px; } </style>
Now your page will have a light blue background, your heading will be dark blue and large, and your paragraphs will be bigger. Each rule inside the curly braces changes one thing about how that tag looks. You can change colors, sizes, spacing, alignment, and hundreds of other properties. As your page grows, moving CSS to its own file keeps your HTML cleaner and lets you reuse the same styles across multiple pages.
Testing your page in different browsers
Once you have saved your HTML file, open it in more than one browser to make sure it looks right everywhere. Open Firefox, Chrome, Safari, and Edge — they all read HTML the same way, but sometimes small differences appear. If your page looks broken in one browser, check your HTML for typos or missing closing tags.
Use your browser's developer tools to find problems. Right-click on your page and select "Inspect" or "Inspect Element." A panel will open showing your HTML code and any errors the browser found. This is the fastest way to spot a missing tag or a CSS rule that is not working. Most developers spend more time in these tools than anywhere else.
If your page is not showing up at all, check three things: the file extension is .html (not .txt), the file is saved in a location you can find, and you are opening it by double-clicking the file itself (not typing the filename into the browser's address bar).
Moving your page to the internet with web hosting
Right now your page only exists on your computer. To make it visible to other people, you need to upload it to a web server — a computer that stays on all the time and is connected to the internet. This service is called web hosting, and companies like GoDaddy, Bluehost, and Namecheap sell it.
When you buy hosting, you get access to a file manager where you can upload your HTML and CSS files. Most hosting providers give you a straightforward drag-and-drop interface. You upload your files, and they become visible at a web address (called a domain) that you choose or register. If you name your main file index.html, the server will show it automatically when someone visits your domain.
For a single page or a small project, you do not need expensive hosting. Many free options exist — GitHub Pages, Netlify, and Vercel all let you upload HTML files and make them public for no cost. These services are designed for people learning to build pages, and they handle the server part for you.
Using a code editor to write cleaner HTML
Notepad works, but a code editor makes writing HTML faster and catches mistakes before you save. Popular free options are Visual Studio Code (called VS Code), Sublime Text, and Atom. These programs highlight your HTML tags in different colors so they are easier to read, auto-complete closing tags when you type an opening one, and show you line numbers so you can find errors quickly.
VS Code is the most popular choice for beginners. read it, install it, and open a new file. Type your HTML, then save it as index.html. The editor will recognize the .html extension and start highlighting your code. You still open the file in a browser the same way — the editor just makes the writing part less frustrating.
Code editors also have built-in terminals and extensions that connect to hosting services, so you can upload your files without leaving the editor. As you build more pages, these tools save hours of clicking around in file managers.
Common mistakes that break your page
The most frequent error is a missing closing tag. If you open an <h1> tag, you must close it with </h1>. If you forget, everything after that tag will be treated as a heading until the browser gives up and closes it for you — which usually breaks your layout. Always check that every opening tag has a matching closing tag.
The second mistake is saving the file with the wrong extension. If you save as index.txt instead of index.html, the browser will try to open it as plain text instead of reading the HTML code. Always double-check the filename before you save.
The third is typing the file path wrong in a link or image tag. If you have a picture called photo.jpg in the same folder as your HTML file, the tag should be <img src="photo.jpg">. If you type <img src="photos/photo.jpg"> and the file is not in a photos folder, the image will not show. Use relative paths (just the filename if it is in the same folder) unless you have a specific reason to use absolute paths.
Frequently Asked Questions
Do I need to know programming to create a web page?
No. HTML is not a programming language — it is a markup language, which means you are just labeling what things are (this is a heading, this is a paragraph, this is a link). You type tags and content, save the file, and the browser does the work of displaying it. If you can follow instructions and type accurately, you can create a web page.
Can I edit a web page after I upload it to the internet?
Yes. You edit the HTML file on your computer, save it, and upload the new version to your hosting service. The changes will appear on the internet within seconds. Most hosting providers let you edit files directly in their file manager too, though editing on your computer and uploading is safer because you have a backup.
What is the difference between a web page and a website?
A web page is a single HTML file. A website is a collection of pages linked together. You create a website by making multiple HTML files (like index.html, about.html, contact.html) and linking them with <a> tags so visitors can move between them.
Do I have to use HTML, or are there other ways to create pages?
HTML is the foundation — every page on the internet uses it. You can use tools like WordPress, Wix, or Squarespace that let you build pages without writing HTML directly, but they generate HTML behind the scenes. Learning HTML gives you more control and understanding of how pages actually work.
How do I add a form where people can enter information?
Use the <form> tag with input fields inside it. A straightforward contact form looks like: <form><input type="text" placeholder="Your name"><textarea></textarea><button>Send</button></form>. However, receiving and storing the information requires a backend service — HTML alone cannot do that. Services like Formspree or Netlify Forms handle this for you.