Skip to content
TrySitePrice

What is my browser size

Four different widths, all correct, all measuring something else. This shows every one your browser reports, live as you resize, and says what each actually measures — including the scrollbar that sits inside the number CSS uses.

Measuring your window

These numbers come from your own browser, so they appear once the page has run.

Questions about viewport size

01Why are there four different widths?

Because they measure four different things. innerWidth is the layout viewport and MDN is explicit that it includes the vertical scrollbar. documentElement.clientWidth is that viewport without the scrollbar. outerWidth is the whole browser window including its chrome. visualViewport is what is actually visible, which changes with pinch-zoom and an on-screen keyboard.

02Which number do CSS media queries use?

The layout viewport — the innerWidth figure. That is why a layout can break at a width your design tokens say is fine: the scrollbar is inside that number, and your content is sitting in the smaller clientWidth.

03What is device pixel ratio for?

It is how many device pixels one CSS pixel covers. On a 2x screen an image needs twice these dimensions to look sharp, which is why the physical pixel count is shown next to it.

04Can this tell me what device I am on?

No, and it does not try. A phone in a split-screen browser, a desktop window dragged narrow and a tablet in portrait can all report the same width. If you are testing a layout, the width is what matters and the device name is not.

05Is any of this sent to a server?

No. Every number is read from your own browser in your own tab. Nothing about your screen leaves the page.

Related tools