I'm curious how many hashes per sec my cpu is able to perform, is there some way to check this?

This is a follow-up to this question.

2 Answers 2


Most CPUs will do a few megahash per second, which is completely worthless for anything other than testing and has been for several years now. It may be possible to improve performance in the future as Skylake Intel x86 processors include specific instructions for SHA256, but only by a few percent. Even with improvements it is a waste of time and power attempting to use anything but the most efficient dedicated hardware. A large portion of ASIC miners are effectively obsolete due to their power requirements outstripping their output, and they are orders of magnitude more efficient than mining on a CPU.

  • 1
    This is not technically true. You can still enable the internal miners using the -gen option, and using the setgenerate RPC. It is non-optimized and slow though, even for a CPU miner. Commented Aug 12, 2015 at 8:40
  • @PieterWuille My mistake, I conflated the removal of getWork with removal of the miner entirely. Running bitcoin-cli setgenerate true does seem crash bitcoind though, wish I hadn't learned that in production.
    – Claris
    Commented Aug 12, 2015 at 14:07
  • 1
    Please report that as a bug. As long as the feature exists, it should work. Commented Aug 12, 2015 at 14:09

Yes Erik, the mining feature is still built-in and you can check how many hashes your CPU can perform. Although it's pointless and you cannot earn anything, it is still a fun experiment that people like to try. If you have a bitcoin core installed and synced with the network, you can just simply open the command console and type in and enter:

setgenerate true

This will initiate your CPU and will start mining. You can then get your hashrate by typing in


Your hashrate will be shown in integer format and you should see a number like 1-3 million hashes per second. To turn off the mining, because you will just be wasting energy type in

setgenerate false

  • so I'm using osx and those commands are not available by default.
    – erikvold
    Commented Oct 2, 2015 at 20:28
  • I guess this should be the accepted answer then! Commented Dec 11, 2020 at 5:03
  • This answer is really old and outdated. setgenerate was removed in version 0.13 because mining with bitcoin core on mainnet is useless and has been for a number of years. bitcoin.stackexchange.com/a/70696/26873
    – m1xolyd1an
    Commented Dec 11, 2020 at 6:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.