Lesson 1 of 10 · about 8 min

How websites work

A website can feel like magic until you see how simple the pieces are. When someone types an address or taps a link, their browser asks a computer somewhere in the world for the website's files, then shows them on screen. That's it. Four things make it happen.

The domain name is the address people type, like mamapendobakes.co.ke, and you rent it year by year from a registrar. The hosting is a computer, called a server, that stores your files and sends them out to visitors day and night. The files are the website itself: HTML, CSS, images, and sometimes JavaScript. And the browser, Chrome, Safari or Edge on the visitor's phone or computer, turns those files into the page they see.

You type the addressmamapendobakes.co.ke
The domain is looked upIt points to the right server
Hosting sends the filesHTML, CSS, images
The browser shows the pageIn about a second
What happens when someone opens a website.
The three languages of the web

HTML is the content and structure: the headings, paragraphs, images, links and buttons. CSS is the look: the colours, fonts, spacing and layout, and how the page adapts to phones. JavaScript adds behaviour, like menus that open, sliders and calculations. Plenty of simple business sites need very little of it, or none at all.

Think of a house. HTML is the walls and the rooms, CSS is the paint and the furniture, and JavaScript is the electricity that makes things move.

HTMLThe walls and rooms: content and structure
CSSThe paint and furniture: the look and layout
JavaScriptThe electricity: things that move and react
The three languages of the web, as a house.
Three ways to build a website

Website builders, like Google Sites, Wix, Squarespace and Hostinger's builder, let you drag and drop. They're the fastest way to start, though the extra features usually come with monthly fees. WordPress runs a huge share of the internet and is very flexible with themes and plugins, but it needs hosting and regular updates. And writing HTML and CSS yourself, which is what this course teaches, is fast, cheap to host (often free), and means you understand exactly how everything works. That makes builders and WordPress far easier later on, too.

Way to buildSpeed to startRunning costControl
Website builderFastestMonthly fees for extrasLimited
WordPressMediumHosting + updatesHigh
HTML and CSS yourselfMediumOften freeComplete
Three ways to build a website. This course teaches the third, which makes the other two easier later.
Do you even need a website? Lots of small businesses start with WhatsApp Business, Instagram and a Google Business Profile, and that's fine. A website adds trust, shows up in Google searches, and is the one place online that you completely control.
Try it: On a computer, open any website, right-click and choose View page source. Find the <title>, a heading (<h1>) and a link (<a href=…>). Don't worry about understanding all of it. Just notice that every website is made of files like these.

Enjoying it? Create a free account to save your progress. Create free account