Skip to main content
Polygon PoS is structured as a two-layer system: a consensus layer called Heimdall-v2 and an execution layer called Bor. Nodes on Polygon are designed around this two-layer split. Bor handles block production; Heimdall-v2 handles validation, checkpoint submission, and coordination with Ethereum. Figure: Ethereum, Bor and Heimdall architecture

Three-layer view

The network can be described as three layers:
  • Ethereum layer: a set of contracts on Ethereum mainnet. These include staking contracts, checkpoint storage, and the bridge.
  • Heimdall-v2 layer: a set of proof-of-stake nodes running in parallel to Ethereum mainnet. Heimdall-v2 monitors staking contracts on Ethereum, validates Bor block data, and submits checkpoints to Ethereum. Built on Cosmos SDK and CometBFT.
  • Bor layer: a set of block-producing nodes shuffled by Heimdall. Built on Go Ethereum.

Staking contracts on Ethereum

The PoS mechanism relies on staking management contracts deployed on Ethereum mainnet. These contracts:
  • Allow anyone to stake POL tokens and register as a validator.
  • Distribute staking rewards for validating state transitions on the network.
  • Record checkpoints submitted by Heimdall.
The PoS mechanism also provides a partial mitigation for the data unavailability problem on Polygon sidechains, since checkpoint data is anchored to Ethereum.

Heimdall-v2: validation layer

Heimdall-v2 aggregates blocks produced by Bor into Merkle trees and publishes the Merkle root periodically to Ethereum. These periodic snapshots are called checkpoints. For every set of Bor blocks, a Heimdall-v2 validator:
  1. Validates all blocks since the last checkpoint.
  2. Creates a Merkle tree of the block hashes.
  3. Publishes the Merkle root hash to Ethereum mainnet.
Checkpoints serve two purposes:
  • Providing finality on Ethereum for cross-chain withdrawals.
  • Providing proof of burn for asset withdrawal to Ethereum.
Block producer selection works as follows:
  • A subset of active validators from the pool is selected as block producers for a span. These producers create and broadcast blocks.
  • A checkpoint includes the Merkle root hash of all blocks in a given interval. All nodes validate the hash and attach their signatures.
  • A proposer from the validator set collects all signatures and submits the checkpoint to Ethereum mainnet.
  • Validator selection probability is proportional to stake ratio in the overall pool.
Heimdall-v2 is a complete rewrite of the original Heimdall. It is based on Cosmos SDK and CometBFT. The migration is specified in: Throughout these docs, “Heimdall” refers to Heimdall-v2 unless otherwise specified.

Bor: block production layer

Bor is Polygon PoS’s block producer, responsible for aggregating transactions into blocks. Block producers are a rotating subset of validators selected periodically by Heimdall based on stake. See Bor architecture for detailed mechanics.