Get the number of CPU cores in Javascript

Get the number of CPU cores in Javascript

Chrome Canary currently supports a new property which represents the amount of CPU cores on the client machine. To retrieve the number of CPU cores in Javascript use:

navigator.hardwareConcurrency

When executed in the console:

navigator-hardwareConcurrency

One thought on “Get the number of CPU cores in Javascript

Leave a Reply

Your email address will not be published. Required fields are marked *