Getting started

How a website loads: from browser to server and back

Follow one page view from typing a URL to a finished page: DNS lookup, TCP and TLS, the HTTP request, PHP and database work, caching and rendering in the browser.

BeginnerEveryone2 min read

Opening a web page feels instant, but a chain of steps happens in a fraction of a second. Knowing the chain shows you where speed is won or lost and which part your hosting controls.

The journey, step by step

  1. You enter a URL such as https://example.com/shop.
  2. DNS lookup: the browser finds the server's IP address, usually from a cache. See how DNS resolution works.
  3. Connection: the browser opens a connection to the server, over TCP (HTTP/1.1 and HTTP/2) or QUIC (HTTP/3).
  4. TLS handshake: browser and server agree on encryption and the browser checks the SSL certificate. See SSL/TLS and HTTPS explained.
  5. HTTP request: the browser asks for /shop, sending headers and cookies.
  6. Server work: the web server checks its cache. On a cache hit it returns the stored page at once. Otherwise it hands the request to PHP, which runs the application code, queries the database and builds the HTML.
  7. Response: the server sends the HTML, compressed with Brotli or gzip.
  8. More requests: the browser reads the HTML and fetches CSS, JavaScript, fonts and images, many in parallel over the same connection.
  9. Rendering: the browser builds the layout and paints the page; scripts make it interactive.

Where time is spent

StageWhat helps
DNS and connectionFast DNS, a server location near your visitors (latency), HTTP/3.
Server processing (time to first byte)Page caching, a fast web server like LiteSpeed, NVMe storage, up-to-date PHP, enough CPU and memory.
Downloading assetsOptimised images, fewer and smaller scripts, browser caching, a CDN.
RenderingLean themes, deferred JavaScript, stable layouts.

What your hosting controls

The host is responsible for the server side: network, web server, storage, PHP versions and server-level caching. MdmHost uses LiteSpeed with NVMe storage, which pairs with the LiteSpeed Cache plugin for WordPress. The front end (theme, images, scripts) is up to the site itself.

Next steps

Was this guide helpful?

Still stuck?

Ask MdmHost AI for a quick answer, or open a ticket and our team will take a look. We are here 24/7.