Learn
5.1.5 | WEB PROTOCOLS
01 | WHAT THIS LESSON CONNECTS
When you enter a URL, the browser must identify the resource, locate the server, request the content and display the result.
This lesson is labelled Web Protocols in the course navigation. The specification’s central requirement is to describe how a web page is located, retrieved and displayed, including the browser, IP addresses, DNS, the web server and HTML.
DNS and HTTP have different jobs: DNS helps resolve a host name to an address; HTTP defines the web request and response. Neither is the page’s markup language.
02 | START WITH THE URL
Use this invented teaching URL:
https://learn.example.org/courses/lesson.html
| Component | Value | What the browser needs it for |
|---|---|---|
| Scheme | https | Choose secure web communication |
| Host name | learn.example.org | Identify the host whose address is needed |
| Path | /courses/lesson.html | Identify the requested resource at that host |
DNS does not look up the whole URL including its page path. The browser normally asks for address information associated with the host name.
03 | WHY AN IP ADDRESS IS NEEDED
An IP address identifies a network interface or destination for IP communication. Routers use destination IP information to forward packets towards the appropriate network.
People often find names easier to remember than numeric addresses. The browser therefore needs a way to obtain an appropriate address for the host name.
For this lesson’s example, suppose the host resolves to 192.0.2.25. This is an illustrative address, not a claim about the real location of a website.
A host can have several addresses, and an address can support several websites. Do not assume every domain has exactly one permanent IP address.
04 | DNS: RESOLVE THE HOST NAME
DNS stands for Domain Name System. A domain name server provides DNS information used to resolve names.
In the simple teaching model, the browser’s device requests the IP address associated with the host name. A DNS server returns suitable address information, enabling communication with the web service.
DNS is a distributed system, not one server holding every answer. A resolver may consult other DNS servers to obtain the required information.
The browser, device or resolver may already have a valid cached answer. In that case, a fresh lookup through the full DNS system is not always necessary.
05 | DNS DOES NOT SEND THE WEB PAGE
DNS LOOKUP
Question: what address is associated with learn.example.org?
Answer in this example: 192.0.2.25
WEB REQUEST
Question: provide /courses/lesson.html on that host.
Answer: a web response, including the page if available.
The DNS service supplies name-resolution information. The web server supplies the requested web resource. These are distinct roles even if services are hosted on related infrastructure.
06 | ESTABLISH COMMUNICATION
With suitable address information, the browser establishes communication with the server. For an HTTPS URL, a secure connection is set up before the web content is exchanged.
Certificate checks help authenticate the server for the requested host. Encryption and integrity protection help protect the exchange in transit.
The IP address guides network delivery; the host name remains important for selecting and authenticating the intended web service.
You do not need to memorise transport-handshake details for this syllabus point. Focus on the roles and the order of the main steps.
07 | SEND THE WEB REQUEST
The browser sends an HTTP request for the resource. A common method for retrieving content is GET.
In our example, the request identifies /courses/lesson.html and the intended host. With HTTPS, the HTTP exchange is carried through the secure connection.
DNS has already served its purpose: it helped obtain the address. It does not search the server’s folders for the page.
08 | THE WEB SERVER RESPONDS
The web server processes the request and returns a response. A successful response can include the requested HTML; an unsuccessful response can indicate a problem.
| Example status | Meaning |
|---|---|
| 200 OK | The request succeeded |
| 404 Not Found | The requested resource was not found at that address |
| Redirect response | The client is directed towards another resource address |
A server may supply an existing HTML file or generate content using server-side software. The browser receives the resulting response, not necessarily the server’s original source program.
09 | HTML AND DISPLAY
HTML describes page structure, such as headings, paragraphs and links. The browser processes it to create the displayed page; this is rendering.
The HTML may refer to other resources such as a stylesheet, an image or a script. The browser can send additional requests to retrieve them.
CSS helps control presentation; client-side JavaScript can add behaviour. The display may develop as resources arrive rather than appearing through one universal all-at-once process.
HTTP is not HTML: HTTP governs the exchange, while HTML describes the document returned through it.
10 | THE WHOLE SEQUENCE
- Read the URL.
The browser identifies the scheme, host and resource path.
- Resolve the host name.
DNS supplies suitable IP address information, unless a usable cached answer is already available.
- Connect to the server.
The browser establishes communication; HTTPS adds a secure connection.
- Request the resource.
The client sends an HTTP request for the path on the intended host.
- Receive the response.
The web server returns status information and the available content.
- Render the page.
The browser processes HTML and other resources, requesting additional files if needed.
Describe the sequence in connected sentences. Explain each role rather than just listing DNS, IP, HTTP and HTML.
11 | DIAGNOSE DIFFERENT FAILURES
| Situation | Possible explanation |
|---|---|
| Host name cannot be resolved | A name or DNS problem prevents obtaining suitable address information |
| Connection cannot be established | The destination or network route may be unavailable |
| Server returns 404 | The server responds, but the requested resource is not found |
| Page text appears but an image is missing | A separate resource request may have failed |
| Old content appears | A cached copy may be involved |
A 404 response does not mean DNS necessarily failed: the browser has received a response from a web server. Separate steps can succeed or fail independently.
12 | COMMON MISTAKES
- DNS downloads HTML: it supplies name-resolution information.
- DNS resolves every character in a URL: the host name is the relevant lookup component.
- The IP address identifies the page path: the request selects the resource on the host.
- The web server displays the page on your screen: the browser renders the returned content.
- HTTP and HTML are identical: exchange rules differ from document structure.
- Every visit repeats a full DNS lookup: valid cached answers may be used.
- A missing image proves the whole connection failed: individual resource requests can fail.