Guides / Web

Debugging a mobile web page without guessing

Use Console, Network, Elements and storage inspection to replace “the page is broken” with evidence you can act on.

PUBLISHED · UPDATED · 10 MIN

“It does not open” is an accurate user experience but a very broad engineering report. The same symptom can mean a JavaScript exception, an API timeout, an overlay covering a button, stale service-worker cache or lost authentication.

The goal is to turn a feeling into reproducible evidence.

Record the scene before repeated refreshes

Keep the full URL, device, OS, browser and version, exact action sequence and the first point of failure. Note whether it occurs only in an in-app browser, installed PWA or private mode.

Android and Chrome remote inspection

  1. Enable USB debugging in Android Developer options.
  2. Connect with a data-capable cable and approve the computer on the phone.
  3. Open the failing page in mobile Chrome.
  4. Open chrome://inspect/#devices in desktop Chrome.
  5. Find the tab and choose Inspect.

If the device is absent, check the cable, USB mode, driver and authorisation prompt. A charging cable is not necessarily a data cable.

USB debugging grants powerful access. Authorise only a trusted computer and revoke or disable debugging when it is no longer needed.

Where to look first

Console

Start with the earliest red error. Later messages may be consequences. Capture the text, file and line rather than a screenshot of the red icon alone.

Network

Enable Preserve log and reproduce the failure. A 404 is a missing path; 401/403 suggests authentication or policy; 429 is throttling; 5xx is server-side; CORS or CSP indicates a browser policy; a request stuck Pending may be a network or long-connection problem.

Elements

A visible but unclickable control may sit under a transparent overlay, have the wrong z-index, or be outside the effective viewport. Inspect the element actually receiving the click.

Application

For an installed PWA or stale interface, inspect Service Workers, Cache Storage, local storage and cookies. Clear the affected site's state only after identifying it; wiping every browser login is not a diagnostic method.

When no computer is available

A test build can include a temporary in-page error panel for window.onerror and unhandled promises. Never expose tokens, cookies, user input or full private responses in a production panel.

In-app browsers need evidence too

An in-app browser may differ in engine version, cache, identity state and available viewport. Failure in WeChat while system Chrome works narrows the problem, but does not by itself prove blocking. Compare the failed request, file-picker behaviour, viewport and connection technology.

A useful report

Include URL, time, device and browser, network, reproduction steps, expected and actual results, the first Console error and the failed Network request. For deployment-related failures, add the commit or version and use the Pages deployment guide to separate code, build, cache and domain layers.

DevTools does not repair a page automatically. It replaces “broken” with a testable claim such as “the API returned 403” or “an old service worker served the bundle.” One good piece of evidence beats ten energetic refreshes.

Official reference: Chrome remote debugging documentation