I am trying to perform a script that should run only on Chrome 64-bit version browsers. Is there a way to check using JavaScript if the Chrome version installed on a user's machine is 64-bit or 32-bit? t should be browser-specific, because for example I run a 64-bit OS and a 32-bit version of Chrome.
So far I managed to detect if the open browser is Chrome and what version of it using Bowser. But I am still struggling with the 64-bit browser detection.
For extensive discussion of this question, see
The bottom line is that the property you are looking for is navigator.platform
, which returns the platform of the browser, not the operating system.
You might also take a look at platform.js, a platform detection library.
EDIT
After looking into this further, it seems that while navigator.platform
should reflect the browser platform, the actual value returned is not always useful.
For example, on Windows, both the 32-bit and 64-bit versions return "Win32". In that case, the user agent string has the better value of either WOW64 for the 32-bit browser or x64 for 64-bit.
Ultimately it seems like the better solution is to rely on canonical lists like in the linked questions, or use a library like platform.js.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With