ParentHash

Storage Plain v101 → v411

Hash of the previous block .

Explore chain
Queried by: validatorsdevelopers

The Big Picture

Part of block header. Links each block to its parent.

Use Cases

  • Verify block lineage

From Chain Metadata

Hash of the previous block.

Purpose & Usage

Purpose

Link to parent block in chain.

Common Query Patterns

  • Single value query

Stored Value

value (H256)

Code Examples

import { createClient, Binary } from "polkadot-api";
import { getWsProvider } from "polkadot-api/ws";
import { sub } from "@polkadot-api/descriptors"; // generated by: npx papi add sub -w wss://entrypoint-finney.opentensor.ai:443

const client = createClient(getWsProvider("wss://entrypoint-finney.opentensor.ai:443"));
const api = client.getTypedApi(sub);

// Query ParentHash storage (no keys - plain value)
const result = await api.query.System.ParentHash.getValue();
console.log("ParentHash:", result);

Version History

v101 block 1 Added
v149 block 3,014,339 Internal re-bind
v151 block 3,157,274 Internal re-bind Current

Runtime Info

Pallet
System
Storage Kind
Plain
First Version
v101
Current Version
v411