<p>I assume that you are talking about a Pay to Public Key Hash (P2PKH) address.</p>
<p><a href="https://en.wikipedia.org/wiki/Cryptographic_hash_function" rel="nofollow noreferrer">Cryptographic hash functions</a> have the <em>pre-image resistance</em> property:</p>
<blockquote>
<p>Given a hash value <code>h</code>, it should be difficult to find a message <code>m</code> for which <code>h = hash(m)</code>.</p>
</blockquote>
<p>P2PKH addresses encode a locking script that commits funds to the hash of a public key. Given that the address only provides the hash, it is not possible to guess the public key from the address as that would require breaking the <em>pre-image resistance</em> property of RIPEMD-160.</p>

CC BY-SA 4.0
2021-07-16T09:20:27.077Z
So it is not possible to get the public key?
rage0920
CC BY-SA 4.0
2021-07-18T16:22:07.183Z
No, you cannot learn the original value if you only have a hash.
Murch
CC BY-SA 4.0
2021-07-15T20:49:58.220Z
2021-07-18T16:21:43.570Z
2021-07-18T16:21:43.570Z
Murch
<p>I was wondering if there is a way to obtain public key of a public address where the address does not have any output transaction</p>

CC BY-SA 4.0
2021-07-15T10:59:58.250Z
Are you looking for the public key to your own address or someone else's?
Murch
CC BY-SA 4.0
2021-07-15T20:34:35.043Z
I'm looking for the public key of the btc puzzle
rage0920
<transactions><public-key>
What are the ways to obtain public key of a wallet with no outputs
rage0920
# What are the ways to obtain public key of a wallet with no outputs

(Asked by: username_0 on 2021-07-15)

I was wondering if there is a way to obtain public key of a public address where the address does not have any output transaction

**Tags:** transactions, public-key

> **Comments:**
> **username_1**: Are you looking for the public key to your own address or someone else's?  
> **username_0**: I'm looking for the public key of the btc puzzle  

---

## 1 answers

### Answer by username_1 on 2021-07-15. Score: 1

I assume that you are talking about a Pay to Public Key Hash (P2PKH) address.

[Cryptographic hash functions](https://en.wikipedia.org/wiki/Cryptographic_hash_function) have the *pre-image resistance* property:

> Given a hash value `h`, it should be difficult to find a message `m` for which `h = hash(m)`.

P2PKH addresses encode a locking script that commits funds to the hash of a public key. Given that the address only provides the hash, it is not possible to guess the public key from the address as that would require breaking the *pre-image resistance* property of RIPEMD-160.

> **Comments:**
> **username_0**: So it is not possible to get the public key?  
> **username_1**: No, you cannot learn the original value if you only have a hash.  

---

