Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

216
Views
Why does outerWidth give different values for some websites?

I wonder why window.outerWidth gives me a bigger value at Stackoverflow.com than at other websites in my browser. I have just noticed this behaviour only on Firefox and Stackoverflow. Shouldn't it be the same on all websites?

In MDN Web Docs it says:

Window.outerWidth read-only property returns the width of the outside of the browser window. It represents the width of the whole browser window including sidebar (if expanded), window chrome and window resizing borders/handles.

Example outerWidth at fullscreen:

  • Stackoverflow: 2070
  • Discord.com and the others in my tabs: 1863

So far I haven't found any website that has a similar behaviour.

console.log( window.outerWidth )

steps to to reproduce it

  1. visit stackoverflow.com
  2. open Developertools / Console
  3. write window.outerWitdh
  4. visit google.com or other side
  5. write window.outerWitdh in the console

In Firefox 95 on Ubuntu 18.04 lts these two values are different. Stackoverflow has a larger value.

about 4 years ago · Santiago Trujillo
1 answers
Answer question

0

  • You are running StackOverflow.com at 90% zoom.

    • Assuming that 2070px is your browser windows' actual width on your desktop, then if you multiply that by 0.9 (90%) then you get 1863px (2070 * 0.9 == 1863).
  • When you run Firefox at different zoom level, Firefox multiplies all other measurements of the page's environment (including the browser and viewport) so the page doesn't actually know it's being zoomed.

  • Reset your zoom level in all your Firefox tabs to 100% and then numbers will match.

about 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!