MaxAllowedValidators

Storage Map v101 → v411

Maximum validators on a subnet .

Explore chain
Queried by: validatorsdelegatorssubnet ownersdevelopersanalytics

The Big Picture

Each subnet has limited validator slots. MaxAllowedValidators caps how many neurons can hold ValidatorPermit. This creates competition - only the top stakers become validators. The rest are miners.

Why This Matters

How many validators can this subnet have? MaxAllowedValidators. The top N by stake get permits. If there are 256 neurons and 64 validator slots, top 64 validate, rest mine.

Example Scenario

Query MaxAllowedValidators(netuid=1) returns 64. Subnet 1 allows 64 validators. The 64 neurons with highest stake have ValidatorPermit = true.

Common Questions

What if I'm just outside the top N?
You're a miner. To become a validator, either accumulate more stake to pass someone, or wait for a current validator to lose stake/deregister.
Can subnet owners change this?
Yes, it's a hyperparameter. Increasing allows more validators; decreasing removes permits from the lowest-stake validators.
Why limit validators?
Consensus efficiency. Too many validators slow down weight processing and consensus. The limit balances decentralization with performance.

Use Cases

  • Check how many validators a subnet allows
  • Determine stake needed for validator permit
  • Compare subnet structures
  • Build validator slot availability displays
  • Research subnet governance designs

From Chain Metadata

MAP ( netuid ) --> max_allowed_validators

Purpose & Usage

Purpose

Limit validator count - only top stakers can validate.

Common Query Patterns

  • Query by netuid
  • Check validator slots available
  • Research subnet structure

Query Keys

#NameTypeDescription
1
netuid
u16 netuid (u16, hashed key component)

Stored Value

max_allowed_validators (u16)

Relationships

Modified By

Related Events

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 MaxAllowedValidators storage
const netuid = 1;

const result = await api.query.SubtensorModule.MaxAllowedValidators.getValue(netuid);
console.log("MaxAllowedValidators:", result);

Version History

v101 block 1 Added
v123 block 720,235 Internal re-bind
v149 block 3,014,339 Internal re-bind
v166–v194 · runtime versions skipped on chain (never deployed)
v195 block 3,791,350 Internal re-bind
v278–v289 · runtime versions skipped on chain (never deployed)
v290 block 5,947,548 Internal re-bind Current

Runtime Info

View Source
Pallet
SubtensorModule
Storage Kind
Map
First Version
v101
Current Version
v411