How the Web Works

Web Development · 3 minute lesson

Every visit to a website starts a conversation. Your browser is the client: it asks a server for a resource, such as an HTML document. The server sends a response containing a status code, headers, and usually a body. The browser reads that response and displays the page.

HTML supplies the structure, CSS controls presentation, and JavaScript adds behavior. A page often needs several requests because stylesheets, scripts, fonts, and images are separate resources. Browser developer tools can show these requests in the Network panel.

Static sites return stored files. Dynamic sites can build responses using application code and a database. Joomla is one example: PHP prepares the page on the server, while your browser receives the resulting HTML. Understanding this boundary helps you decide where a feature belongs and where to investigate a failure.

Try the example

GET /index.php HTTP/1.1
Host: example.com

HTTP/1.1 200 OK
Content-Type: text/html

Practice

Open developer tools, select Network, and reload this page. Find the main document and one stylesheet. Compare their content types and response status codes.

Continue learning: Official documentation.