Observe fixed response delays
See how a controlled server delay contributes to, but does not fully determine, client-observed elapsed time.
- timing
- latency
- requests
Prediction
A larger fixed server delay should increase browser elapsed time, but the two numbers should not be expected to match exactly.
Controlled observation
Choose 0, 250, 1000, or 3000 milliseconds. The response reports the selected fixture while the browser records elapsed time around the complete Fetch.
Explanation
Client-observed elapsed time includes more than application waiting. Connection, TLS, routing, queueing, edge execution, transfer, and browser scheduling can all contribute. This exercise isolates one known component without claiming to measure network latency or server processing independently.
Controlled exercise
Run this observation
Compare the fixed server delay with browser elapsed time; network and client overhead remain part of the elapsed result.
Ready. No request has run.
Controlled request
- Method
- GET
- URL
https://lab.httpclarity.com/v1/delay/0- Permitted headers
- None
- Body
- None
Browser-observed response
No live response yet. The representative static example remains useful without JavaScript or the Worker.
Static response example
HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
X-Lab-Scenario: delay
{"milliseconds":0,"scenario":"delay"}Timing is browser elapsed time. Fetch hides Set-Cookie, raw wire bytes, reliable compressed size, and some redirect details.
Portable examples
'curl' '--include' '--request' 'GET' 'https://lab.httpclarity.com/v1/delay/0'Scroll horizontally to read any long lines.const response = await fetch("https://lab.httpclarity.com/v1/delay/0", {
"method": "GET"
});
console.log(response.status, await response.text());Scroll horizontally to read any long lines.<?php
$options = ['http' => [
'method' => 'GET',
'ignore_errors' => true,
]];
$context = stream_context_create($options);
$body = file_get_contents('https://lab.httpclarity.com/v1/delay/0', false, $context);
var_dump($http_response_header, $body);Scroll horizontally to read any long lines.Need a full API client? Copy the generated cURL command, then import it in Hoppscotch. HTTPClarity sends no request data to Hoppscotch.
Continue in Hoppscotch (opens in a new tab)Primary sources
- W3C High Resolution Time Level 3 (primary documentation)
