If I try to get info in genesis block, there is 1 tx:

  "scriptPubKey": {
    "asm": "0496b538e853519c726a2c91e61ec11600ae1390813a627c66fb8be7947be63c52da7589379515d4e0a604f8141781e62294721166bf621e73a82cbf2342c858ee OP_CHECKSIG",
    "hex": "410496b538e853519c726a2c91e61ec11600ae1390813a627c66fb8be7947be63c52da7589379515d4e0a604f8141781e62294721166bf621e73a82cbf2342c858eeac",
    "type": "pubkey"

bitcoin-cli decodescript gives me this address:

  "asm": "0496b538e853519c726a2c91e61ec11600ae1390813a627c66fb8be7947be63c52da7589379515d4e0a604f8141781e62294721166bf621e73a82cbf2342c858ee OP_CHECKSIG",
  "type": "pubkey",
  "p2sh": "3BgShGBxRQrczVD6Ftj4z51FfgJ761FdSX"

However any block chain explorers show address 12c6DSiU4Rq3P4ZxziKxzrL5LmMBrzjrJX. The same problem with 2, 3, 4... blocks. Why?


Some of the earlier transactions on the bitcoin network use a raw public key in a p2pk script, instead of the now-common p2pkh format.

Only the p2pkh format is representable as an address. The raw p2pk script has no corresponding address, and must be worked with as a script directly. Some explorers and other tools will attempt to show it as either a p2sh address for the hash of that script, or as its p2pkh version, but that is not accurate to the actual on-chain data.

  • 2
    Moreover, if you sent money to the "address" that's generated by the blockchain explorers, the wallet in question would never see that money as it isn't looking for P2PKH scripts. It's a really bad "feature" that many of them have implemented. – Pseudonymous Mar 10 '20 at 6:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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