HTML stands for HyperText Markup Language. It is the code every web page is built from: plain text with labels, called tags, wrapped around each part of the content to say what it is. One tag marks a heading, another a paragraph, another a link or an image. A browser reads those labels and turns them into the page you see. You can run a business website for years without writing a line of it, but the HTML is what search engines, screen readers and email programs actually read.
In short
- The code that gives a web page its structure.
- Tags label each part: heading, paragraph, link, image.
- CSS adds the look and JavaScript adds the behaviour.
- Search engines read the HTML, not the design.
How HTML works
An HTML file is a document of nested elements. Each element starts with an opening tag, holds some content, and ends with a closing tag. A paragraph sits inside paragraph tags, a link sits inside link tags with the address it points to, and the whole page sits inside one outer element with two parts: the head, holding information about the page, and the body, holding what visitors see.
Tags can carry attributes, which add detail. A link has an attribute for its destination, an image has one for its file and one for its description, and a form field has one saying what kind of input it expects. When a browser receives the file, it reads the elements in order and builds the page from them.
The rules are published as a standard that every browser follows, which is why the same page works in Chrome, Safari and Firefox. HTML5 was the name given to the version that added elements for video, audio and page sections, and the standard is now updated continuously rather than in numbered releases.
HTML, CSS and JavaScript
A web page is usually three kinds of code working together.
- HTML says what each part is: this is the main heading, this is a list, this is the navigation.
- CSS says how it looks: colours, fonts, spacing and how the layout changes on a phone.
- JavaScript says how it behaves: a menu that opens, a form that checks an address, a cart that updates.
Keeping them separate is what lets a site be redesigned without rewriting its content, and why a page with JavaScript switched off can still be read if the HTML underneath is sound.
It also explains a common fault. Some sites build their content with JavaScript after the page loads, so the HTML that first arrives is nearly empty. Browsers cope, but search engines and link previews may see far less than a visitor does. Asking a developer whether the main text is in the HTML from the start is a fair question for any new build.
What search engines and screen readers read
Google does not look at the design. It reads the HTML and works out from it what the page is about and how it is organised.
- The title tag sits in the head and becomes the clickable line in search results, which is why the title tag carries so much weight.
- Headings give the page an outline, and a heading chosen for its size instead of its level breaks that outline.
- Link text tells the reader and the search engine what is at the other end.
- Alt attributes describe images for anybody who cannot see them, which is what alt text is.
- Structured data, usually written as JSON-LD, describes the business, the product or the article in a fixed format.
Screen readers depend on the same structure. A button built as a real button can be reached and pressed with a keyboard; a styled box that only looks like one often cannot.
Where you meet it without writing it
Most business owners touch HTML indirectly.
- The editor in your website. A content management system turns what you type into HTML when you press publish.
- Pasted text. Copying from a word processor can carry hidden formatting into the page, which is why pasted text sometimes appears in the wrong font or size.
- Email. Designed emails are HTML too, written in an older, stricter style because email programs support far less than browsers do.
- Embed codes. A map, a booking widget or a video is added by pasting a block of HTML someone else wrote.
Checking it yourself
You do not need to read code fluently to spot problems. Open a page, right-click and choose View Page Source, then search the text for a few things: the title, the main heading, and whether the words on the page are really there as text or only inside images. The browser’s developer tools show the same code and highlight each part of the page as you hover over it. If your main sales message cannot be found in the source, a search engine cannot find it either.
Words you will hear
- Tag. A label in angle brackets that opens or closes an element.
- Element. A complete piece of the page, from opening tag to closing tag.
- Attribute. Extra detail inside a tag, such as a link’s address.
- Head and body. The two halves of a page: information about it, and its content.
- Semantic HTML. Using the element that describes the content, such as a real heading or a real button.
- Markup. The tags as a whole, as opposed to the text they wrap.
Open your homepage source today and look for your main heading as plain text. If it is missing, or the page has more than one competing main heading, that is a small fix with a large effect on how the page is read.
Questions we get
More about html
What does HTML stand for?
Is HTML a programming language?
What is the difference between HTML, CSS and JavaScript?
What is HTML5?
Does a business owner need to learn HTML?
How do I see the HTML of a web page?
Why does HTML matter for SEO?
Do it yourself
Guides on the same topic
Free step by step guides for owners doing the work themselves. No sign up and no email required.
Related terms
Website
A website is the set of pages your business owns at its own address, and the only place online where you decide what customers see and what they can do.
Heading
Headings are the titles that divide a page, marked H1 to H6. They give the page an outline for readers, screen readers and search engines alike.
Content management system
A content management system is the admin area where a website is edited without code. Which one you are on decides who can change what, and at what cost.