Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Configuring Zebra

Zebra 7.0.0 reads configuration from a TOML file and environment variables. The file represents the ZebradConfig Rust type. Keep only settings that must differ from the defaults; copying every generated value into a permanent configuration prevents later releases from updating those values automatically.

Without -c or --config, Zebra looks for zebrad.toml in the user’s preference directory:

PlatformDefault configuration file
Linux$XDG_CONFIG_HOME/zebrad.toml, or $HOME/.config/zebrad.toml
macOS$HOME/Library/Preferences/zebrad.toml
Windows%LOCALAPPDATA%\zebrad.toml, in the local application-data directory

Zebra uses defaults and environment variables when the default file is absent. Starting a node with an explicitly selected file requires that file to exist and be readable. Select a file with:

zebrad --config /path/to/zebrad.toml start

Generate a default configuration with:

zebrad generate --output-file zebrad.toml

The command overwrites the output file. Without --output-file, it writes to standard output. It generates built-in defaults, not the merged configuration of a running node. Optional fields whose default is absent are not included. The generated file reflects the features compiled into that binary. The generate command ignores configuration-loading errors so it can produce a replacement for an invalid configuration.

The loader applies these sources, from highest to lowest priority:

  1. Environment variables with the ZEBRA_ prefix.
  2. The selected TOML file.
  3. Built-in defaults for omitted fields and sections.

Command-specific overrides apply afterward. See Tracing for filter syntax and Docker for container configuration.

Every top-level section listed below rejects unknown keys, and the root rejects unknown sections. The nested network-parameter, activation-height, funding-stream, recipient, and lockbox-disbursement structs also reject unknown keys. The Regtest selector wrapper described below is an exception: it does not reject unknown sibling keys beside params and regtest. A field compiled out of the schema, such as an Elasticsearch state field without the elasticsearch feature, is an unknown field. Fields whose implementation is feature-gated can still be accepted; their behavior is specified below. Unknown fields and invalid types fail configuration loading rather than silently using defaults.

In the tables, absent means None: omit the key to leave it unset. TOML has no null; an empty string, false, or empty array is a value, not an unset instruction. Optional fields can have nonempty defaults. Removing a file setting does not cancel an environment override.

Write durations as quoted humantime strings, such as "5m", "1h", or "1m 1s". Address fields are strings containing an IP address and port, with brackets around IPv6 addresses. Only the two peer-to-peer (P2P) address fields permit an omitted port. A block height is an integer; validated consensus heights are at most 2147483647. Amounts are in zatoshis, with 100000000 zatoshis per ZEC.

The default cache directory used below is:

PlatformDefault cache directory
Linux$XDG_CACHE_HOME/zebra, or $HOME/.cache/zebra
macOS$HOME/Library/Caches/zebra
Windows%LOCALAPPDATA%\zebra
No platform cache directory availablecache/zebra under the current working directory

On Linux, the XDG directory variables must contain absolute paths. Empty or relative values use the corresponding home-directory fallback.

The P2P cache, state database, and RPC cookie have separate settings even when their defaults share this directory. Give each concurrently running node a separate state directory and RPC cookie directory. Protect configuration files containing credentials and directories writable by a privileged Zebra process from modification by other users.

Environment variables

  • Zebra strips the exact, case-sensitive ZEBRA_ prefix, lowercases the key, and replaces each __ with a nested-table separator. Single underscores remain in field names.
  • Use leaf variables or TOML, not JSON or TOML objects as whole-table values. Configure activation heights in TOML: lowercasing loses case-sensitive names such as Canopy and NU7.
  • Values are parsed as case-insensitive booleans, signed 64-bit integers, floating-point numbers, then strings. Empty values are not ignored. Shell-quote spaces in durations and filters; shell quotes are not part of the value.
  • There is no list separator or general array parser. Put peer arrays, network magic, checkpoints, and funding streams in TOML, not comma-separated or JSON-array environment values. Only the two JSON-array-string fields in [zcashd_compat] accept arrays through environment values.
  • Zebra rejects leaf keys ending in password, secret, token, cookie, or private_key, ignoring case, even for unknown fields. Store these values in the file. This rejects ZEBRA_STATE__ELASTICSEARCH_PASSWORD, but not path fields such as cookie_dir.
  • For copy-state, use ZEBRA_TARGET_ variables with --target-config-path to override target settings, for example ZEBRA_TARGET_STATE__CACHE_DIR=/srv/zebra-target. The source/base loader ignores this prefix. Only the target’s [state] settings are used, although the whole file is deserialized. Without --target-config-path, the target uses an ephemeral state configuration and ignores target overrides.
Environment variableTOML setting
ZEBRA_NETWORK__NETWORK=Testnet[network] network = "Testnet"
ZEBRA_RPC__LISTEN_ADDR=127.0.0.1:8232[rpc] listen_addr = "127.0.0.1:8232"
ZEBRA_STATE__CACHE_DIR=/srv/zebra[state] cache_dir = "/srv/zebra"
ZEBRA_HEALTH__READY_MAX_TIP_AGE=10m[health] ready_max_tip_age = "10m"
ZEBRA_NETWORK__TESTNET_PARAMETERS__CHECKPOINTS=true[network.testnet_parameters] checkpoints = true
export ZEBRA_ZCASHD_COMPAT__ZCASHD_EXTRA_ARGS='["-debug=1"]'
export ZEBRA_ZCASHD_COMPAT__BLOCK_GOSSIP_PEER_IPS='["127.0.0.1","::1"]'

[consensus]

Rust API: zebra_consensus::Config.

FieldTypeDefaultMeaning
checkpoint_syncBooleantrueUse the selected network’s full checkpoint list during synchronization. Setting false starts full verification earlier, but does not disable mandatory checkpoints. Developer-only option; disabling it makes synchronization slower and weakens protection against chain attacks.
debug_skip_parameter_preloadBooleanfalseObsolete compatibility key. Zebra accepts it, ignores its value, and omits it when generating configuration.

[network]

Rust API: zebra_network::Config and CacheDir.

FieldTypeDefaultMeaning
listen_addrIP address string, optional port"[::]", resolved to "[::]:8233" on MainnetP2P listener. An omitted port becomes 8233 on Mainnet or 18233 on Testnet and Regtest. The generated Mainnet configuration includes the explicit port.
external_addrOptional IP address string, optional portAbsentAddress advertised to peers instead of the listener address, for network address translation (NAT), containers, or load balancers. Does not change the bind address. Uses the selected network’s default port if omitted.
networkNetwork-name string or parameter table"Mainnet"Select "Mainnet", "Testnet", or "Regtest", or use a configured-network table as described below.
experimental_early_block_relayBooleanfalseExperimental next-tip block relay with peers that also enable it. Negotiated peers can serve authenticated blocks before full transaction validation; Zebra still fully verifies every block, and ordinary relay of committed blocks is unchanged. Uses a temporary service bit until a production one is allocated.
initial_mainnet_peersArray of address stringsMainnet seed list belowInitial Mainnet peers; each IP address or DNS name must include a port. Duplicate strings are removed while preserving order.
initial_testnet_peersArray of address stringsTestnet seed list belowInitial Testnet peers. Regtest removes public seed names and retains only resolved loopback addresses.
cache_dirBoolean or path stringtrueUse the default cache directory when true, disable the peer disk cache when false, or use the supplied directory. Independent of [state] cache_dir.
peerset_initial_target_sizeusize25Initial peer target. Also sets the outbound connection limit to three times this value and the inbound limit to five times it. Zero produces a warning and becomes 25.
crawl_new_peer_intervalDuration string"1m 1s"Interval between routine peer-address crawls. Zebra also crawls when all peers are busy and no connection candidates remain. The old key new_peer_interval is an accepted alias.
max_connections_per_ipusize1Concurrent peer-connection limit per IPv4 address or IPv6 /64 subnet. Also affects inbound reconnection rate limiting. Zero produces a warning and becomes 1; increasing it reduces peer diversity protections.
testnet_parametersOptional tableAbsentCompatibility layout for Testnet or Regtest parameters, used with a string-valued network selector. Ignored for Mainnet and when network itself contains parameters.

The exact default Mainnet seed list is:

initial_mainnet_peers = [
    "dnsseed.str4d.xyz:8233",
    "dnsseed.z.cash:8233",
    "mainnet.seeder.shieldedinfra.net:8233",
    "mainnet.seeder.zfnd.org:8233",
    "seeder.zec.rocks:8233",
]

The exact default Testnet seed list is:

initial_testnet_peers = [
    "dnsseed.testnet.z.cash:18233",
    "seeder.testnet.zec.rocks:18233",
    "testnet.seeder.zfnd.org:18233",
]

Place either array in [network]. An empty array removes those seeds; it does not disable inbound connections or the disk peer cache. Regtest skips loading the peer cache. Peer cache files use <cache_dir>/network/<network-directory>.peers.

The listener and external address parsers accept IP literals, not DNS names. The default unspecified listener accepts connections without advertising an unspecified address.

Configured network layouts

Use Custom Testnets or Regtest for complete network examples. Both of these layouts select the same parameter schema:

[network]
network = "Testnet"

[network.testnet_parameters]
checkpoints = true
[network.network]
checkpoints = true

A table-valued selector with a params child selects Regtest instead:

[network.network.params.activation_heights]
NU5 = 1

The Regtest selector wrapper has these fields:

Field under [network.network]TypeDefaultMeaning
paramsParameter tableRequired for the Regtest table formSelects Regtest and contains its parameters. Omit the entire table to use the string selector instead.
regtestOptional booleanAbsentAccepted marker in the Regtest table form; the deserializer ignores its value. The presence of params, not this boolean, selects Regtest.

[network.testnet_parameters]

These fields also apply under [network.network] for configured Testnet or [network.network.params] for Regtest.

FieldTypeDefaultMeaning
network_nameOptional stringAbsent; configured name "UnknownTestnet"Custom Testnet name, at most 30 UTF-8 bytes, containing only alphanumeric characters or _. Case-insensitive reserved names are Mainnet, Testnet, Regtest, MainnetKind, TestnetKind, and RegtestKind. Unchanged public parameters can retain the canonical name Testnet. Ignored on Regtest, whose name is Regtest.
network_magicOptional array of four u8 integersAbsent; [250, 26, 249, 191] on TestnetP2P wire identifier. Mainnet [36, 233, 39, 100] and Regtest [170, 232, 63, 95] magic values are reserved. On Regtest, only [170, 232, 63, 95] is accepted.
slow_start_intervalOptional block heightAbsent; 20000 on TestnetSubsidy slow-start interval in blocks; the slow-start shift is half this value. On Regtest, only 0 is accepted.
target_difficulty_limitOptional hexadecimal unsigned 256-bit integer stringAbsent; compact-rounded 2^251 - 1 on TestnetMaximum expanded proof-of-work target, not a fixed target for every block. Compact conversion can discard low-order precision; invalid or zero values fail startup. On Regtest, only the compact-rounded 256-bit value consisting of 32 0x0f bytes is accepted.
disable_powOptional booleanAbsent; false on TestnetDisable proof-of-work checks for an isolated test network. On Regtest, only true is accepted.
genesis_hashOptional 64-digit hexadecimal stringAbsent; 05a60a92d99d85997cce3b87616c089f6124d7342af37106edc76126334a2c38Testnet genesis block hash. On Regtest, only 029f11d80ef9765602235e1bc9727e3eb6ba20839319f761fee920d63401e327 is accepted.
activation_heightsOptional tableAbsent; public Testnet schedule belowReplace the activation schedule, not individual public-network defaults. Without overrides, Regtest activates through Canopy at height 1; later upgrades remain inactive.
nsm_reissuance_heightOptional block heightAbsentOverride the calculated first Network Sustainability Mechanism (NSM) reissuance height. Must be nonzero and within the height range. Without an override, Zebra calculates the ZIP 237 scheduled-issuance crossover; a custom schedule can have no crossover.
pre_nu6_funding_streamsOptional funding-stream tableAbsentLegacy funding-stream group prepended before the current list. Missing group fields inherit the first public Testnet group.
post_nu6_funding_streamsOptional funding-stream tableAbsentLegacy group inserted after the pre-NU6 legacy group and before the current list. Missing group fields inherit the second public Testnet group.
funding_streamsOptional array of funding-stream tablesAbsent; public Testnet groups below, or [] on RegtestReplace the funding-stream list. An explicit [] disables streams.
pre_blossom_halving_intervalOptional u32Absent; 840000 on TestnetPre-Blossom halving interval in blocks, in 1..=2147483647. Later intervals are derived. On Regtest, only 144 is accepted, giving 288 after Blossom and 864 after NU7.
lockbox_disbursementsOptional array of disbursement tablesAbsent; ten public Testnet outputs below, or [] on RegtestExpected one-time lockbox outputs at NU6.1 activation. An explicit [] removes them.
checkpointsBoolean, path string, or array of [height, hash] pairsfalse in a parameter tableWith false, use only the configured genesis checkpoint; with true, use the public Testnet checkpoint list. Strings are file paths, not a "default" selector. An array supplies the list directly. Plain network = "Testnet" without a parameter table uses the full public list instead. Regtest defaults to genesis only.
extend_funding_stream_addresses_as_requiredOptional booleanAbsent; no extensionWhen true, repeat configured funding-stream address sequences to cover their required address periods.
temporary_orchard_disabling_soft_fork_heightOptional block heightAbsent; 4048500 on TestnetOverride the start height of the temporary Orchard-action restriction, which ends at NU6.2 activation. Omission does not disable it on Testnet, and there is no TOML disabling switch. Rejected on Regtest, where the restriction is disabled.
should_allow_unshielded_coinbase_spendsOptional booleanAbsent; true on RegtestRegtest-only permission for transactions spending coinbase outputs to have transparent outputs. Zebra rejects this field on configured Testnet, even when set to false.
initial_nsm_value_balanceOptional integer amountAbsent; 55768414957 zatoshis with public Testnet magic, otherwise 0NSM reserve seeded at NU7. Explicit values must be between 0 and 2100000000000000 zatoshis. Regtest defaults to 0.

See Custom Testnets for cross-field validation and activation, subsidy, funding-stream, and checkpoint rules.

For inline checkpoint pairs, each hash is an array of 32 u8 values in serialized byte order: reverse the byte order of the displayed hexadecimal hash, not its individual digits. A hexadecimal string is not accepted here. For human-readable hashes, use a checkpoint file: each line contains a height and its displayed hexadecimal hash, separated by one space.

Activation heights

The activation table is [network.testnet_parameters.activation_heights] in the compatibility layout. All fields are optional u32 heights and default to absent in an explicitly supplied table. The public schedule column applies only when the whole table is omitted on Testnet.

FieldTypeDefault in supplied tablePublic Testnet height
BeforeOverwinterOptional heightAbsent1
OverwinterOptional heightAbsent207500
SaplingOptional heightAbsent280000
BlossomOptional heightAbsent584000
HeartwoodOptional heightAbsent903800
CanopyOptional heightAbsent1028500
NU5Optional heightAbsent1842420
NU6Optional heightAbsent2976000
"NU6.1"Optional heightAbsent3536500
"NU6.2"Optional heightAbsent4052000
"NU6.3"Optional heightAbsent4134000
NU7Optional heightAbsent4465026
ZFutureOptional heightAbsentNot activated; key exists only with --cfg zcash_unstable="zfuture"

Quote upgrade names containing dots so TOML does not interpret them as nested keys. Each supplied height must be in 1..=2147483647.

Funding streams and lockbox outputs

Each funding_streams array element or legacy table configures one group:

FieldTypeDefaultMeaning
height_rangeOptional table with start and endAbsent; inherit the corresponding public Testnet groupInclusive start, exclusive end of the group’s block heights. Entries beyond the three public default groups must provide this field.
recipientsOptional array of recipient tablesAbsent; inherit the corresponding public Testnet groupReplace the group’s recipients. An explicit [] leaves the group without recipients. Entries beyond the three public default groups must provide this field.

Each supplied height_range has these required fields:

FieldTypeDefaultMeaning
startBlock heightRequiredFirst height in the group. Must not exceed end.
endBlock heightRequiredFirst height after the group; equal start and end produce an empty range.

Each supplied recipient has these fields:

FieldTypeDefaultMeaning
receiverString enumRequiredOne of "ECC", "ZcashFoundation", "MajorGrants", or "Deferred".
numeratoru64RequiredShare of the block subsidy over a fixed denominator of 100.
addressesOptional array of stringsAbsent; empty address sequenceTransparent funding addresses in period order. Deferred recipients do not require addresses. Non-deferred recipients use P2PKH or P2SH addresses, not tex addresses.

On Testnet and Regtest, Zebra rejects invalid ranges, missing defaults, numerator totals above 100, and malformed addresses during loading. Non-deferred recipients need Testnet addresses covering every address period. Extension can repeat a nonempty list but cannot fill a required empty list.

The three public Testnet groups are, in order:

Height range, end exclusiveReceiver sharesAddress defaults
1028500..2796000ECC 7/100, Zcash Foundation 5/100, Major Grants 8/100The 51-entry FUNDING_STREAM_ECC_ADDRESSES, FUNDING_STREAM_ZF_ADDRESSES, and FUNDING_STREAM_MG_ADDRESSES lists in the Testnet funding constants.
2976000..3396000Deferred 12/100, Major Grants 8/100No deferred addresses; 13 copies of t2HifwjUj9uyxr9bknR8LFuQbc98c3vkXtu for Major Grants.
3536500..4497948Deferred 12/100, Major Grants 8/100No deferred addresses; 27 copies of t2HifwjUj9uyxr9bknR8LFuQbc98c3vkXtu for Major Grants.

Public address sequences are consensus data, not operator payout addresses.

Each lockbox_disbursements element has these fields:

FieldTypeDefaultMeaning
addressStringRequiredTransparent address receiving the specified one-time disbursement.
amountInteger amountRequiredOutput value in zatoshis, from 0 through 2100000000000000.

Zebra validates lockbox addresses during loading. The sum of all disbursements must not exceed 2100000000000000 zatoshis.

The default Testnet list contains ten identical outputs, each paying 787500000000 zatoshis to t2RnBRiqrN1nW4ecZs1Fj3WWjNdnSs4kiX8.

Rust API: ConfiguredActivationHeights, ConfiguredFundingStreams, ConfiguredFundingStreamRecipient, and ConfiguredLockboxDisbursement.

[state]

Rust API: zebra_state::Config.

FieldTypeDefaultMeaning
cache_dirPath stringDefault cache directoryRoot of the state database and non-finalized-state backup. Does not relocate peer caches or RPC cookies.
ephemeralBooleanfalseStore the database in a temporary directory instead of cache_dir, and disable non-finalized-state backups. The temporary database is removed on successful cleanup; a crash can leave it behind.
should_backup_non_finalized_stateBooleantrueBack up recent blocks outside the finalized database so they can be restored after a restart. Disabled by ephemeral; otherwise updates occur no more frequently than every five seconds.
delete_old_databaseBooleantrueCheck for and delete obsolete state database versions. Setting false disables old-version cleanup, not migration of a compatible previous database.
debug_stop_at_heightOptional u32AbsentCommit blocks to finalized state up to the selected height, then exit. Developer option; omission keeps syncing.
debug_validity_check_intervalOptional duration stringAbsentRun additional periodic state-validity checks. Without it, normal format checks still run at startup and shutdown.
debug_skip_non_finalized_state_backup_taskBooleanfalseDeveloper option: replace the periodic backup task with synchronous writes before non-finalized-state and chain-tip updates. Does not disable restoring backups or override ephemeral/backup disabling.
elasticsearch_urlString; elasticsearch feature only"https://localhost:9200"Elasticsearch service URL for experimental indexing.
elasticsearch_usernameString; elasticsearch feature only"elastic"Elasticsearch HTTP Basic authentication username.
elasticsearch_passwordString; elasticsearch feature only""Elasticsearch HTTP Basic authentication password. Redacted from debug output, but stored in plaintext in the configuration file. Environment overrides are rejected.
elasticsearch_skip_cert_validationBoolean; elasticsearch feature onlyfalseDisable HTTPS certificate validation. Use only for trusted local clusters with self-signed certificates; credentials and indexed data can be intercepted.

Persistent state uses <cache_dir>/state/v29/<network-directory> in Zebra 7.0.0. Non-finalized backups use <cache_dir>/non_finalized_state/<network-directory>. Do not share a live state directory between node processes. Deleting state forces the node to download and verify the chain again; it is not a configuration-reset procedure.

The Elasticsearch client validates HTTPS certificates by default. Configure a trusted server certificate, or explicitly opt out for a trusted local cluster with elasticsearch_skip_cert_validation = true. HTTP never protects credentials. See Elasticsearch indexing.

[sync]

Rust API: zebrad::components::sync::Config.

FieldTypeDefaultMeaning
download_concurrency_limitusize50Parallel block-download requests. Values below 1 are raised to 1 with a warning. The old key max_concurrent_block_requests is an accepted alias.
checkpoint_verify_concurrency_limitusize1000Blocks submitted concurrently to checkpoint verification. Values below 400 are raised to 400 with a warning. The old key lookahead_limit is an accepted alias.
full_verify_concurrency_limitusize20Blocks submitted concurrently to full verification. Values below 1 are raised to 1 with a warning.
parallel_cpu_threadsusize0Rayon worker threads for CPU-intensive verification. Zero delegates thread-count selection to Rayon; a positive value overrides its automatic selection.

Do not supply both an alias and its current key: they deserialize as duplicate fields.

With zero threads configured, Rayon uses a positive RAYON_NUM_THREADS environment value, otherwise the available logical CPU count, with a one-thread fallback if detection fails. If that environment variable is absent or invalid, Rayon also checks the deprecated RAYON_RS_NUM_CPUS before detecting the CPU count. An explicit RAYON_NUM_THREADS=0 selects CPU detection without checking the deprecated variable.

[mempool]

Rust API: zebrad::components::mempool::Config.

FieldTypeDefaultMeaning
tx_cost_limitu6480000000Maximum sum of ZIP 401 transaction costs. Each transaction costs the greater of its serialized byte size and 10000; this is not a literal RAM-byte limit.
eviction_memory_timeDuration string"1h"Retention limit for randomly evicted, mined, expired, and chain-conflicting transaction IDs in rejection caches. Capacity eviction or a mempool reset can remove entries earlier. Does not set transaction lifetimes or retention for every rejection reason.
debug_enable_at_heightOptional u32AbsentForce-enable the mempool once the best chain reaches this height, regardless of synchronization status. Omission retains sync-status gating except on Regtest, where startup always overrides this field to 0.
max_datacarrier_bytesOptional u3283Maximum standard OP_RETURN script size in bytes, including the opcode and pushdata overhead. Omission still uses 83. This is relay policy, not a block-consensus limit.

[rpc]

Rust API: zebra_rpc::config::rpc::Config.

FieldTypeDefaultMeaning
listen_addrOptional socket-address stringAbsentEnable the HTTP JSON-RPC server at this IP address and port. Conventional loopback ports are 8232 for Mainnet and 18232 for Testnet; neither is enabled automatically.
indexer_listen_addrOptional socket-address stringAbsentEnable the indexer gRPC server. The listener itself does not require the indexer feature; that feature enables additional state spend indexes.
lightwalletd_listen_addrOptional socket-address stringAbsentEnable the experimental lightwalletd-compatible CompactTxStreamer gRPC server, for example at 127.0.0.1:9067.
parallel_cpu_threadsusize0Deprecated compatibility field. Accepted but has no effect on the current JSON-RPC server.
debug_force_finished_syncBooleanfalseTest-only override that reports synchronization finished regardless of the estimated tip or local clock.
cookie_dirPath stringDefault cache directoryDirectory containing the JSON-RPC authentication cookie. Must be writable when cookie authentication is enabled.
enable_cookie_authBooleantrueRequire cookie-based HTTP authentication for JSON-RPC. Does not authenticate either gRPC listener.
max_response_body_sizeu3252428800Maximum JSON-RPC response body size in bytes, exactly 50 MiB. Does not configure the request-size limit.

Bind RPC listeners to loopback or a restricted private interface; see JSON-RPC authentication. Neither gRPC listener uses cookie authentication. The lightwalletd-compatible listener serves plaintext HTTP/2 without authentication or TLS; terminate TLS at a controlled proxy before exposing it to clients. See Mining and Docker RPC.

[mining]

Rust API: zebra_rpc::config::mining::Config.

FieldTypeDefaultMeaning
miner_addressOptional Zcash address stringAbsentPayout address for miner subsidy and transaction fees in generated block templates. Must be valid for the selected network and supported by the coinbase builder.
extra_coinbase_dataOptional stringAbsentText appended to the coinbase input after Zebra’s marker and separator. Maximum 86 UTF-8 bytes, not 86 characters; larger values fail configuration loading. Empty text adds no separator.
miner_memoOptional stringAbsentMemo text for a shielded coinbase output, at most 512 UTF-8 bytes. Zebra validates the length even for a transparent-only payout, which does not include the memo; an oversized value prevents template generation.
internal_minerBooleanfalseStart the experimental built-in miner when compiled with internal-miner. Accepted but has no effect without that feature.

The obsolete miner_data key is rejected. Coinbase tag and memo strings are not hex-decoded: "4142" means four UTF-8 bytes, not two.

See Mining for payout validation and template behavior. The internal miner uses one solver; its thread count is not configurable. Treat coinbase metadata as public, including shielded memos; see ZIP 213.

[tracing]

Rust API: zebrad::components::tracing::Config and InnerConfig.

FieldTypeDefaultMeaning
use_colorBooleantrueUse ANSI colors when standard output is a terminal. This test also controls formatted logs sent to log_file; set false for plain-text log files.
force_use_colorBooleanfalseForce ANSI colors even for non-terminal output and even when use_color is false.
filterOptional stringAbsentTracing filter expression for start and copy-state; command-line filters override it. The fallback is info, or debug with -v. The generate and tip-height commands ignore configured and command-line filters: they always use warn, or info with -v.
buffer_limitusize128000Maximum queued log lines for the nonblocking writer. Values below 100 become 100. A full queue drops log lines.
endpoint_addrOptional socket-address stringAbsentEnable the runtime filter-control HTTP endpoint; requires filter-reload. Without the feature, Zebra warns and does not open it.
flamegraphOptional path stringAbsentEnable tracing-span flamegraph collection for start and copy-state; requires flamegraph. Writes .folded data and an .svg graph using the supplied path with its extension replaced. Without the feature, Zebra warns and does not collect it. The generate and tip-height commands ignore this setting.
progress_barOptional string enumAbsentEnable progress rendering with "summary" or "detailed"; requires progress-bar to render. Both modes currently render the same bars. Other string values deserialize as "summary". Setting this field also selects a default log file if none was specified.
log_fileOptional path stringAbsentLog destination instead of standard output. When progress_bar is set, omission selects the platform log path below.
use_journaldBooleanfalseSend tracing events to systemd-journald; requires journald. Without the feature, Zebra warns and does not install that layer.
opentelemetry_endpointOptional URL stringAbsentEnable OpenTelemetry trace export over OTLP HTTP; requires opentelemetry. Falls back to OTEL_EXPORTER_OTLP_ENDPOINT. Zebra appends /v1/traces when absent from the URL suffix.
opentelemetry_service_nameOptional stringAbsentExported service name. Falls back to OTEL_SERVICE_NAME, then "zebra".
opentelemetry_sample_percentOptional u8AbsentTrace sampling percentage. Falls back to OTEL_TRACES_SAMPLER_ARG, then 100; values from 101 through 255 are clamped to 100. Zero samples no traces.

The progress-bar log fallback is $XDG_STATE_HOME/zebrad.log or $HOME/.local/state/zebrad.log on Linux, $HOME/Library/Application Support/zebrad.log on macOS, and %LOCALAPPDATA%\zebrad.log on Windows. Selecting a progress mode changes this log destination even when the binary lacks progress rendering. If no platform state directory is available, Zebra tries the local data directory; if neither path is available, logs remain on standard output.

All tracing fields remain recognized without their optional implementation features. An OpenTelemetry endpoint configured without the feature produces a warning. Exporter initialization failure disables export, not the node. The fallback OTEL_TRACES_SAMPLER_ARG is an integer percentage: 10 means 10%; 0.1 fails parsing and falls back to 100%. Prefer the explicit Zebra setting.

The filter-control endpoint has no authentication. Keep it private: remote changes can increase log volume and reveal operational details. Log files, flamegraphs, and exported traces can also contain node data.

Sentry has no TOML field or [sentry] section. With the sentry feature, set SENTRY_DSN to configure reporting; SENTRY_ENVIRONMENT supplies its environment metadata. See Tracing, Sentry monitoring, and OpenTelemetry export.

[metrics]

Rust API: zebrad::components::metrics::Config.

FieldTypeDefaultMeaning
endpoint_addrOptional socket-address stringAbsentEnable the Prometheus HTTP metrics listener. Requires prometheus; without it, Zebra accepts the field, warns, and leaves the endpoint disabled.

The listener has no configured authentication or TLS. Restrict access to the monitoring network. Failure to bind a configured listener stops startup. See Metrics.

[health]

Rust API: zebrad::components::health::Config.

FieldTypeDefaultMeaning
listen_addrOptional socket-address stringAbsentEnable the health HTTP server.
min_connected_peersusize1Minimum recently live peers for /healthy and, when enforced, /ready. Zero disables the peer-count requirement.
ready_max_blocks_behindi642Maximum estimated lag in blocks accepted by /ready. Negative lag estimates are clamped to zero; a negative configured threshold cannot pass the enforced lag check.
enforce_on_test_networksBooleanfalseWith false, /ready returns HTTP 200 on Testnet, custom Testnets, and Regtest without running readiness checks. Does not bypass /healthy.
ready_max_tip_ageDuration string"5m"Maximum time since the sampled best height last exceeded its previous high-water mark. This is local progress freshness, not the latest block header’s timestamp.

An enforced readiness check also requires a populated state and sync status close to the network tip. The HTTP endpoints are unauthenticated. Bind them to a private interface and restrict access with network policy. See Health checks.

[notify]

Rust API: zebrad::components::notify::Config.

FieldTypeDefaultMeaning
block_notify_commandOptional stringAbsentShell command launched after a best-chain tip change when Zebra is close to the network tip. Every %s becomes the new tip’s 64-digit hexadecimal block hash.
zmqpubhashblockOptional stringAbsentZMQ PUB endpoint for best-chain tip hashes, equivalent to zcashd’s -zmqpubhashblock, for example "tcp://127.0.0.1:28332". Requires a binary built with the zmq feature. Startup fails if the endpoint is invalid or unavailable, or if the feature is missing. The socket has no authentication; expose it only to trusted clients.

Zebra executes the command through /bin/sh -c on Unix or cmd /C on Windows, with the node process’s privileges. Standard input, output, and error are redirected to the null device. Treat this setting as executable code; use only a trusted command or script.

Notification commands run independently of block validation. Notifications are best effort: fast synchronization and reorganizations can coalesce intermediate tips, and a slow command does not prevent later commands from starting. Do not use notifications as an exactly-once block index.

ZMQ notifications follow the same rules, and the publisher also drops messages when its bounded queue overflows. Subscribers must reconcile through RPC after a gap or a reconnect.

[zcashd_compat]

Rust API: zebrad::components::zcashd_compat::Config.

FieldTypeDefaultMeaning
enabledBooleanfalseEnable zcashd-compat mode for a zcashd P2P sidecar. The start --zcashd-compat flag also enables it.
manage_zcashdBooleanfalseSpawn and supervise the sidecar when compatibility mode is enabled. Otherwise zcashd is managed externally.
zcashd_sourceString enum"path"Binary source: "path" uses zcashd_path; "embedded" downloads and caches the release selected by Zebra’s embedded manifest. An explicit path overrides either selection.
zcashd_pathOptional path stringAbsentExplicit sidecar executable, which must be resolvable for supervised "path" mode. This mode does not default to searching for an executable named zcashd.
zcashd_datadirOptional path stringAbsentBase sidecar data directory; falls back to <state.cache_dir>/zcashd-compat-zcashd. A valid extra -datadir=<path> argument overrides it.
zcashd_extra_argsArray of strings, or JSON-array string[]Extra supervised-child arguments. Zebra rejects peer-selection arguments and appends its enforced isolation and foreground flags after these arguments.
p2p_connect_addrOptional socket-address stringAbsentZebra P2P address passed to the supervised child’s -connect. Defaults to Zebra’s actual bound listener, substituting loopback in the same IP family for an unspecified address.
block_gossip_peer_ipsArray of IP strings, or JSON-array string[]Trusted sidecar source IPs. An empty list becomes 127.0.0.1 and ::1 while compatibility mode is enabled. A nonempty list is rejected when compatibility mode is disabled.
startup_delayDuration string"1s"Delay before the first supervised spawn attempt.
restart_backoffDuration string"2s"Initial restart delay for exponential backoff. Must be greater than zero when supervising.
restart_backoff_maxDuration string"5m"Maximum restart delay. Must be greater than zero when supervising.
restart_reset_afterDuration string"1h"Child uptime that resets the consecutive restart count. Setting "0s" disables the reset.
shutdown_grace_periodDuration string"5m"Time allowed for clean child shutdown after SIGTERM before forced termination.

The embedded source supports Linux x86-64. Startup runs compatibility-mode preflight checks.

The extra-argument validator rejects -connect, -addnode, and -seednode, including negated forms and variants with extra leading dashes or different case. The supervisor sets its own peer connection, disables incoming P2P, DNS seeding, onion listening, and discovery, and forces foreground operation. For data-directory and configuration-file preparation, Zebra uses the last valid -datadir=<path> or -conf=<path> argument, also accepting -- forms. It warns about duplicates, empty paths, or paired arguments such as ["-conf", "file"]; paired values are passed through but not inferred for preparation. Relative configuration paths resolve under the selected sidecar data directory.

Trust every process able to connect from a listed sidecar IP; never list an address shared with untrusted tenants. The zcashd-compat page describes the sidecar’s reserved inbound capacity, reconnection exemptions, and pinned block gossip.

The connect-address override describes the address the sidecar dials. It does not identify the sidecar’s source IP for privileges. Across containers or hosts, configure the source IP list separately. A non-loopback connect override with an empty trusted list produces a warning because privileges still default to loopback.