Hydration Proof

Search documentation

Find a page or section

HP9004: The page could not be loaded

HP9004 (navigation-failed) means the test browser could not navigate to the URL at all: the server is not running, the URL is wrong or the connection failed.

HP9004 (navigation-failed) means the test browser could not navigate to the URL at all: no response came back, so there is no page to test. The server is not running, the URL is wrong, or the connection failed. Check that the server is running and the URL is correct.

CodeHP9004
Namenavigation-failed
Default severityError
GroupTest run problems
What it meansThe browser could not navigate to the URL.

What the HP9004 navigation failed finding means

The finding carries the browser's own error, for example a refused connection or a timeout:

page.goto: net::ERR_CONNECTION_REFUSED at http://localhost:3000/pricing

It is an error, and no other check runs on that page. A server that answers with an error status is a different problem: HP9005.

Likely causes

  • With --url, the app is not running, or runs on another port.
  • The app crashed during the run, so every later page fails.
  • A host name that does not resolve, or a certificate the browser rejects.
  • A page that takes longer than the page timeout to respond.

How to fix it

Check that the server is running and the URL is correct.

  1. With --url, start the app first and open the URL in your own browser.
  2. Without --url, hydration-proof starts the app itself; check that server.command works on its own, and raise server.timeout for slow starts.
  3. If only some pages fail, check the app's own logs for a crash during the run.
  4. For occasional failures, let hydration-proof load the page again with retries (on CI the default is 1).
npx hydration-proof test --url http://localhost:3000 --route /pricing --retries 2

A run that stops before any page with "chromium is not installed" is not this finding: download the browser once.

npx hydration-proof install