<p>When validating a block, the verifier has to know all the transactions in full.</p>
<p>So they can just recompute the Merkle root from the transaction hashes, and compare it with the one stored in the block header.</p>

CC BY-SA 4.0
2021-11-10T18:18:03.780Z
Hi Pieter,

Thanks for answering.

So when a block gets confirmed/validated, is it the miner that checks the transactions, rather than next block? Because the block itself won't hold all the transactions from the previous block.
lodeboon
CC BY-SA 4.0
2021-11-10T18:21:46.710Z
When verifying/mining a block, you check all the transactions in the block itself. The transactions from previous blocks have already been verified in the past.
Pieter Wuille
CC BY-SA 4.0
2021-11-10T16:35:44.037Z
2021-11-10T16:35:44.037Z
Pieter Wuille
<p>I am trying to understand how another block validates the transactions through the merkle root. Shouldn't it be impossible to know what hashes the merkle root is hashed from because you can't reverse it?</p>
<p>For instance, if there are 4 transactions. 0 and 1 are hashed together, 2 and 3 are hashed together and combining these together they are the merkle root. Yet, due to it all being hashed, how can another block or someone validate transaction 2?</p>

<blockchain><block><merkle-tree>
How can a block validate a merkle-root if it is all hashed?
lodeboon
# How can a block validate a merkle-root if it is all hashed?

(Asked by: username_0 on 2021-11-10)

I am trying to understand how another block validates the transactions through the merkle root. Shouldn't it be impossible to know what hashes the merkle root is hashed from because you can't reverse it?

For instance, if there are 4 transactions. 0 and 1 are hashed together, 2 and 3 are hashed together and combining these together they are the merkle root. Yet, due to it all being hashed, how can another block or someone validate transaction 2?

**Tags:** blockchain, block, merkle-tree


---

## 1 answers

### Answer by username_1 on 2021-11-10. Score: 1 | Accepted answer

When validating a block, the verifier has to know all the transactions in full.

So they can just recompute the Merkle root from the transaction hashes, and compare it with the one stored in the block header.

> **Comments:**
> **username_0**: Hi Pieter,  Thanks for answering.  So when a block gets confirmed/validated, is it the miner that checks the transactions, rather than next block? Because the block itself won't hold all the transactions from the previous block.  
> **username_1**: When verifying/mining a block, you check all the transactions in the block itself. The transactions from previous blocks have already been verified in the past.  

---

