BIP 122 Blockchain URI Scheme: This guide explains BIP 122 URI scheme for Blockchain references / exploration in plain English. It covers the problem behind the BIP, why it matters and whether the proposal is part of Bitcoin today.
TL;DR
- What it is: BIP 122 proposes a blockchain URI for portable references to transactions, blocks and addresses. A handler can open the user's preferred explorer or local application instead of embedding one website into every document.
- Why it matters: BIP 122 offers a clean idea for portable blockchain references, but its draft status and custom-handler boundary require cautious parsing, explicit chain identity and a clear distinction between lookup and validation.
- Current position: The Application-layer specification remains Draft, so support is optional and parsers must not treat an identifier or external handler as trusted validation evidence.
BIP 122 Blockchain URI Scheme in simple English
BIP 122 Blockchain URI Scheme: The proposal uses blockchain:[//chain]/type/value. Type is tx, block or address. Transactions use a 64-hex identifier.
Simple example
A node operator is checking BIP 122 Blockchain URI Scheme. Transactions use a 64-hex identifier. Blocks may use a 64-hex hash or decimal height.
Key terms in plain English
- BIP:
- Bitcoin Improvement Proposal: a document describing a proposed rule, standard or process. Its status must be checked separately.
- Consensus:
- The shared rules full nodes use to decide whether blocks and transactions are valid.
- Node:
- A computer running Bitcoin software that checks data and communicates with other peers.
General URI shape
The proposal uses blockchain:[//chain]/type/value. Type is tx, block or address. Transactions use a 64-hex identifier; blocks may use a 64-hex hash or decimal height; addresses use the relevant chain's address encoding. Omitting the chain identifies Bitcoin mainnet under the draft's convention.
Chain ID and forks
For a base chain, the chain ID is its genesis block hash including leading zeroes. For a forked chain, the draft uses the first block after the fork. The explicit identifier reduces name ambiguity, but software still needs a trusted registry or user confirmation before selecting a network and data source.
Transactions, blocks and addresses
A transaction reference identifies data, not confirmation or finality. A block height can name a different hash after a reorganisation. An address reference does not prove ownership, payment intent or network safety. The handler should display type, chain and resolved result without silently turning a reference into a spend action.
Parser and dispatch risks
Custom URI handlers receive input from web pages, documents and QR codes. Enforce length, grammar and hexadecimal rules before dispatch. Reject control characters, extra path segments and unsupported schemes. Escape every displayed value, and never construct a shell command or unrestricted web redirect from a raw URI.
Explorer trust boundary
A public explorer can omit, delay or mislabel chain data and learns which objects the user requests. A local validating node provides stronger consensus evidence but may not index every address. Applications should distinguish convenient lookup from local validation and communicate the privacy cost of remote resolution.
Draft status and interoperability
BIP 122 has not become a universally registered Bitcoin application convention. Two handlers may interpret chain omission, address formats or fork identifiers differently. New products should feature-detect support, offer copyable raw identifiers and avoid replacing normal HTTPS links unless the user retains a clear fallback.
Safe fixture suite
Test mainnet, testnet, regtest and a synthetic fork chain with transaction, block-hash, block-height and address references. Add truncated hashes, mixed case, leading-zero loss, huge heights, encoded separators and unknown chains. Confirm that lookup cannot trigger payment, remote code execution or a silent network switch.
Frequently asked questions
What is the main point of BIP 122 Blockchain URI Scheme?
BIP 122 Blockchain URI Scheme: The proposal uses blockchain:[//chain]/type/value. Type is tx, block or address.
For BIP 122 Blockchain URI Scheme, what should a beginner know about general URI shape?
The proposal uses blockchain:[//chain]/type/value. Type is tx, block or address.
For BIP 122 Blockchain URI Scheme, what should a beginner know about chain ID and forks?
For a base chain, the chain ID is its genesis block hash including leading zeroes.
For BIP 122 Blockchain URI Scheme, what should a beginner know about transactions, blocks and addresses?
A transaction reference identifies data, not confirmation or finality. A block height can name a different hash after a reorganisation.
Conclusion
BIP 122 offers a clean idea for portable blockchain references, but its draft status and custom-handler boundary require cautious parsing, explicit chain identity and a clear distinction between lookup and validation.
Primary sources
Check the current specification status and the documentation for the exact implementation you operate before moving production funds or changing a mining node.
Join the ASIC Mining Discussion
Members can read and join the discussion
Log in to read comments from other miners. Create a free account if you would like to ask a question or share your experience.
Membership helps us protect the discussion from spam and keep answers useful.