Exova Academy

Module 1 — Web Fundamentals · 15 min

How a Web Page Gets Displayed, and Setting Up Your Tools

Before writing a single tag, let's spend ten minutes understanding what happens when someone opens a web page, then set up a simple, free workstation. This isn't theory for its own sake: once you know who does what between the browser and the server, you'll understand why a page published on GitHub Pages needs no database and no subscription. By the end of this mini-course, you'll have a personal homepage that looks clean on both phone and desktop, live at a real address you can send to a recruiter, a client or a friend.

What happens when you open a page

When you type an address like https://example.github.io, your browser first asks the Domain Name System (DNS) for the IP address of the server behind that name. It then opens an encrypted connection (the "S" in HTTPS) and sends a request: "give me the home page." The server replies with an HTML file. The browser reads that file, discovers it also needs a CSS stylesheet, images and sometimes scripts, and requests those in turn. Finally, it puts everything together and draws the page on screen.

%% titre: The journey of a web page
%% narration: This diagram follows a page's journey: the browser finds the server's address through DNS, requests the HTML file, then the CSS files and images, before displaying the result.
sequenceDiagram
  participant N as Browser
  participant D as DNS
  participant S as Server
  N->>D: Which IP for this name?
  D-->>N: IP address
  N->>S: GET / (home page)
  S-->>N: index.html file
  N->>S: GET style.css and images
  S-->>N: Requested files
  N->>N: Page rendered
The journey of a web page

Remember one key idea: a homepage is a static site. The files are sent as they are, with no processing on the server. That's exactly what free services like GitHub Pages are built to host. A dynamic site (an online store, a members area) also needs a server-side program and a database: that's a different job, which we'll get to later.

The browser's three languages

The browser understands three languages, each with a specific role:

  • HTML describes the content and its structure: this is a heading, this is a paragraph, this is a link.
  • CSS describes the appearance: colors, fonts, spacing, column layouts.
  • JavaScript adds behavior: responding to a click, loading data, animating things.

For a homepage, HTML and CSS are more than enough. We won't write any JavaScript in this mini-course, and that's a deliberate choice: a page that works without scripts loads faster, is easier for search engines to read and breaks less often.

Setting up your workstation

You need three things, all free:

  1. A modern browser: a recent version of Firefox, Chrome, Edge or Safari. The developer tools (F12, or Cmd+Option+I on a Mac) will be your magnifying glass.
  2. A code editor: we recommend Visual Studio Code (VS Code). It color-codes your code, completes tags and flags errors. Install it from Microsoft's official website, then add the "Live Server" extension, which reloads the page automatically every time you save.
  3. A project folder: create a folder named my-page in your Documents. Avoid spaces and accented or special characters in file and folder names: on a server, My Page é.html quickly becomes a source of broken links.

Open VS Code, go to File > Open Folder, and choose my-page. Create a file called index.html. That name matters: it's the file servers send by default when someone requests the root of a site.

%% titre: Project folder layout
%% narration: This diagram shows the layout we'll follow: a project folder containing the index.html page, the stylesheet and a subfolder for images.
flowchart TD
  A["my-page folder"] --> B["index.html (content)"]
  A --> C["style.css (appearance)"]
  A --> D["images folder"]
  D --> E["photo.jpg"]
  B -- "uses" --> C
  B -- "displays" --> E
Project folder layout

Your first file

Type this into index.html, then save:

<!doctype html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <title>My first page</title>
  </head>
  <body>
    <h1>Hi, my name is Camille</h1>
    <p>This is my first web page.</p>
  </body>
</html>

Right-click inside the file and choose "Open with Live Server": your browser opens and displays the page. Change the paragraph text, save, and watch it update instantly. This "edit, save, look" loop is the heart of a web developer's work.

A few quick explanations. <!doctype html> tells the browser this is modern HTML. The lang="en" attribute declares the language, which helps screen readers pronounce the text correctly. <meta charset="utf-8"> makes sure accented and special characters display properly. The <title> is the text shown in the browser tab and in search results. Everything visible lives inside <body>.

Hands-on practice

Take 10 to 15 minutes to:

  1. Install VS Code and the Live Server extension.
  2. Create the my-page folder with an index.html file containing the code above, using your own first name.
  3. Open the page with Live Server, then open the developer tools (F12), go to the "Network" tab and reload the page. Note which files are requested and their response codes.
  4. Add a second paragraph that says, in one sentence, what you do for a living.
Show solution

Your body should look something like this:

<body>
  <h1>Hi, my name is Camille</h1>
  <p>This is my first web page.</p>
  <p>I'm a sales assistant and I'm learning to build websites.</p>
</body>

In the Network tab, you'll see at least one index.html line (or just the folder name) with a 200 code, which means "everything went fine." Live Server sometimes adds a small technical request for auto-reload: that's normal. If you see a 404 code, the requested file doesn't exist at that location: check the exact name, including uppercase letters.

If accented characters display incorrectly, the <meta charset="utf-8"> line is missing or the file isn't saved as UTF-8 (VS Code shows the encoding in the bottom-right corner of the window).

Key takeaways

  • A page is displayed through several requests: first the HTML, then the CSS, images and scripts it asks for.
  • A homepage is a static site: plain files that can be hosted for free.
  • Your workstation comes down to three tools: a browser, VS Code with Live Server, and a well-named folder.

Go further: the complete "Full-Stack Web Development" course covers HTTP, response codes, headers and how a real server works, then has you build an app with a database. Explore the full course

Enjoyed this lesson?

Unlock all 9 lessons, the quizzes and the certificate.

Buy — $0