Documentation

Zcoin documentation

Zcoin is a privacy-first network for Ecash (ticker E). It does three things: it routes every buy through a Zcash full node so activity is anchored to the Zcash chain, it lets holders convert E directly to ZEC, and it lets holders shield their balances using Zcash's zero-knowledge shielded pools.

These docs describe the design as it will run at launch. Where a parameter is not final it is marked TBA. Where something is not live it is marked Not live.

Project status

Pre-launch. Mainnet genesis has not occurred. The explorer reads block height 0. The Convert and Shield tools are complete interfaces whose backend returns NOT_LIVE for every request.
ComponentStateNotes
Website & docsLiveYou're reading it.
ExplorerScaffoldAll views render from zero state.
Buy routerSpecDesign below; testnet next.
Zcash node fleetSpeczebrad + lightwalletd.
Convert (E→ZEC)Not liveUI complete, placeholder backend.
Shield / UnshieldNot liveUI complete, placeholder backend.
MainnetNot launchedParameters TBA.

Quickstart

Once the network is live, the shortest path from nothing to private ZEC is:

  1. Get a wallet that supports Ecash and Zcash Unified Addresses. Write down the seed phrase offline.
  2. Buy E. Your buy is routed through an Zcoin Zcash node; the explorer will show the Zcash txid next to your purchase.
  3. Shield. Open Shield, choose Orchard, and move your balance into the shielded pool.
  4. Convert (optional). Open Convert, paste your u1… address and swap any amount of E for ZEC.
  5. Verify. Look up your Zcash txid in the Zcoin explorer or any Zcash explorer.

Core concepts

Two kinds of value

Zcash, and therefore Zcoin, supports two kinds of value in one ledger:

  • Transparent value uses a Bitcoin-style UTXO model. Every input, output and amount is public.
  • Shielded value lives in encrypted notes. The chain stores only commitments to notes and nullifiers of spent notes, plus a zero-knowledge proof that everything balances.

Pools

A pool is the set of all value of one kind. Zcash has a transparent pool and shielded pools named after their protocol upgrades: Sprout (legacy, closed to new deposits), Sapling (activated October 2018) and Orchard (activated with NU5 in May 2022). Value moves between pools only through transactions that reveal the amount crossing the boundary, which is why pool totals are public even though individual balances are not.

Anchoring

An Zcoin action is anchored when there is a confirmed Zcash transaction that commits to it. Every buy is anchored by design (see Buy routing). Anchoring gives Zcoin the same finality and censorship resistance as the Zcash chain for those actions.

Units

UnitValue
1 E108 base units (proposed, mirroring Zcash)
1 ZEC100,000,000 zatoshis
Zcash target block time75 seconds (since the Blossom upgrade)

The Ecash token (E)

Project
Zcoin
Token
Ecash
Ticker
E

Ecash is the asset you buy, hold, shield and convert. Its uses are:

  • Medium of exchange between Zcoin users, transparent or shielded.
  • Convertible claim to ZEC via the router, at the quoted rate.
  • Router fees are denominated in E.

Supply, issuance schedule and allocation are listed in Tokenomics and are TBA until published.

Architecture

Zcoin is made of four components. Each can be run by Zcoin and, over time, by independent operators.

Walletkeys stay here Routerorders · quotes · locks zebradZcash full node lightwalletdcompact blocks (gRPC) Zcash networkmainnet Indexer / Explorer

Wallet

Holds the seed, derives Ecash and Zcash keys, signs orders and builds shielded proofs locally. The router never sees spending keys.

Router

The router accepts signed orders, prices them, holds short-lived locks, and constructs the Zcash transactions that anchor each action. It is stateless with respect to custody: it can build and broadcast but cannot spend user funds without a valid user signature.

Zcash node (zebrad)

Zcoin runs Zebra (zebrad), the Rust Zcash full node, as the canonical source of Zcash chain state and as the broadcaster for routed transactions. zcashd is supported for compatibility while it remains maintained, but new deployments should use Zebra.

lightwalletd

lightwalletd serves compact blocks over gRPC so wallets can scan for their shielded notes without downloading full blocks.

Indexer / Explorer

Reads both Ecash state and Zcash anchors and serves the explorer and the public REST API.

Buy routing lifecycle

The defining property of Zcoin: every buy is routed through a Zcash node. Concretely, a buy is not final until a Zcash transaction committing to it is confirmed.

States

StateMeaning
CREATEDWallet signed an order; router received it.
QUOTEDRouter priced it and returned a quote id with expiry.
BUILDINGRouter's node is constructing the anchoring Zcash transaction.
BROADCASTTransaction submitted to Zcash mempool via sendrawtransaction.
ANCHOREDZcash tx mined. Ecash credited. Zcash txid linked.
FINALAnchoring tx reached the finality depth (TBA confirmations).
EXPIREDNot mined before expiry height; order voided, nothing credited.

The anchoring transaction

Each anchoring transaction carries a commitment to the order in its memo or an OP_RETURN-style output:

anchor = BLAKE2b-256(
  personalization = "Zcoin_Anc",
  order_id || buyer_commitment || amount_E || quote_id || ecash_height
)

For privacy, buyer_commitment is a hiding commitment, not the buyer's address. Anyone can verify that an anchor exists for a given order id; only the buyer (or a holder of their viewing key) can link it to themselves.

Expiry

Zcash transactions carry an nExpiryHeight (introduced in Overwinter). The router sets it to a short horizon so stuck orders fail cleanly rather than lingering.

Batching

To keep Zcash fees proportional, the router may batch several orders into one anchoring transaction, with a Merkle root of the order anchors in the memo. Each order's inclusion proof is served by the API.

Converting to ZEC

Convert swaps E for ZEC delivered to an address you control. Open the tool.

Flow

  1. POST /v1/quote returns a rate, fee breakdown, quote id and expiry.
  2. Wallet signs a lock of amount_E referencing the quote id.
  3. Router builds a ZEC transaction from its liquidity to your destination. For u1/zs1 destinations this creates a shielded output note encrypted to you.
  4. On confirmation, the lock finalises and the E is retired from circulation or returned to the liquidity pool (TBA).
  5. If the ZEC transaction doesn't confirm before expiry, the lock is released.

Destination rules

PrefixTypeAcceptedPrivacy
u1Unified Address (ZIP 316)Yes (recommended)Shielded to the best receiver (Orchard first)
zs1SaplingYesShielded
t1 / t3Transparent P2PKH / P2SHYesPublic
tex1TEX (ZIP 320)YesPublic, transparent-source only
zcSproutNoSprout pool closed to new value

Shielding deep dive

Shielding moves value from the transparent pool into a shielded pool. After that, transfers between shielded addresses reveal nothing about sender, receiver or amount. Open the tool.

Notes

A shielded note is roughly (diversifier, pk_d, value, rseed) for Sapling, and similar with an extra rho and psi for Orchard. Notes are never published in the clear.

Note commitments

When a note is created the transaction publishes its note commitment cm, a hiding and binding commitment to the note. Commitments are appended to an incremental Merkle tree (depth 32). The tree root at some height is the anchor a spend proves membership against.

Nullifiers

To spend a note you reveal its nullifier nf, computed from the note and your nullifier-deriving key. Nodes reject any transaction whose nullifier has already appeared, preventing double-spends. Because only the owner can compute nf, observers can't tell which commitment was spent.

Zero-knowledge proofs

Each shielded spend and output comes with a zk-SNARK proving, without revealing anything else:

  • the spent note's commitment is in the tree at the claimed anchor;
  • the spender knows the keys that authorise spending it;
  • the nullifier is correctly derived;
  • input and output values balance (checked via homomorphic value commitments and a binding signature).
SaplingOrchard
ActivatedOct 2018May 2022 (NU5)
Proof systemGroth16Halo 2
Trusted setupYes (multi-party ceremony)None
CurvesBLS12-381, JubjubPallas, Vesta
Transaction unitSpend + Output descriptionsActions (one spend + one output each)
Zcoin defaultSupportedRecommended

Note encryption

The recipient learns about a new note from an encrypted ciphertext attached to the output. The sender does a Diffie-Hellman key agreement with the recipient's diversified transmission key and encrypts the note plaintext and a 512-byte memo with ChaCha20-Poly1305. Wallets trial-decrypt compact outputs from lightwalletd to find their notes.

What remains visible

  • That a transaction occurred, its size, and the number of spends/outputs/actions (padded where possible).
  • The fee.
  • Amounts crossing between pools (shielding and unshielding).
  • Network-level metadata such as your IP address, unless you use Tor or similar.
Best practice: shield once, transact shielded-to-shielded, and avoid unshielding the same distinctive amount you shielded.

Addresses

NetworkPrefixEncodingExample shape
Ecash transparente1Bech32m (proposed)e1q…
Ecash shieldedeu1Unified-style, Bech32m (proposed)eu1…
Zcash transparentt1, t3Base58Check, 35 charst1…
Zcash Saplingzs1Bech32, 78 charszs1…
Zcash Unifiedu1Bech32m with F4Jumble (ZIP 316)u1…

Unified Addresses

A Unified Address bundles several receivers (Orchard, Sapling, transparent) into one string. The sender's wallet picks the most private receiver it supports. Zcoin always prefers the Orchard receiver.

Diversified addresses

One shielded key can generate practically unlimited unlinkable addresses. Give each counterparty its own.

Keys & viewing keys

KeyCan spendSees incomingSees outgoingShare?
Seed / spending keyYesYesYesNever
Full viewing key (UFVK)NoYesYesAuditors only
Incoming viewing key (UIVK)NoYesNoProof of receipts
AddressNoNoNoYes

Keys derive from a BIP-39 seed using ZIP 32 hierarchical derivation. Zcoin wallets derive Ecash and Zcash keys from the same seed under separate paths (TBA coin type).

Fees

Zcash network fee

Zcash uses the ZIP 317 proportional fee mechanism: fee = 5,000 zatoshis × max(2, logical_actions). A simple shielded transaction costs 10,000 zatoshis (0.0001 ZEC). More inputs and outputs cost proportionally more.

Router fee

A router fee in E covers anchoring and liquidity. Rate TBA. The fee is always shown in the quote before you sign.

Running a node

Anyone can run the Zcash side of the stack. A router node needs zebrad, lightwalletd and the Zcoin router service (TBA, to be open-sourced).

Hardware (Zcash mainnet, approximate)

  • 4+ CPU cores, 16 GB RAM
  • 300 GB+ SSD (chain grows over time)
  • Stable broadband; port 8233/tcp open for Zcash P2P

zebrad

# install (Rust toolchain required)
cargo install --locked zebrad

# generate a config and enable RPC
zebrad generate -o ~/.config/zebrad.toml
# ~/.config/zebrad.toml (excerpt)
[network]
network = "Mainnet"
listen_addr = "0.0.0.0:8233"

[rpc]
listen_addr = "127.0.0.1:8232"

[state]
cache_dir = "/var/lib/zebrad"
zebrad start

lightwalletd

git clone https://github.com/zcash/lightwalletd
cd lightwalletd && make
./lightwalletd --grpc-bind-addr 0.0.0.0:9067 \
  --zcash-conf-path ./zcash.conf --data-dir /var/lib/lightwalletd

Zcoin router (placeholder)

# electrocoin-router.toml (proposed)
[zcash]
rpc_url      = "http://127.0.0.1:8232"
lightwalletd = "127.0.0.1:9067"

[router]
listen       = "0.0.0.0:7400"
batch_window = "TBA"
finality     = "TBA"
Never expose the zebrad RPC port to the public internet.

API reference

Base URL https://api.electrocoin.example/v1 (placeholder). All responses are JSON. Until launch every endpoint returns 503 with code NOT_LIVE.

MethodPathDescription
GET/statusNetwork height, Zcash tip, router health
GET/blocks?limit=&before=Paginated blocks, newest first
GET/blocks/{height|hash}Single block
GET/txs/{txid}Single transaction
GET/address/{addr}Transparent balance and history (shielded addresses return 403)
GET/routed?limit=Recent routed buys with Zcash txids
GET/anchors/{order_id}Anchor + Merkle inclusion proof
POST/quotePrice an E→ZEC conversion
POST/convertSubmit a signed conversion lock
POST/shieldRelay a wallet-built shielding tx
GET/poolsTransparent / Sapling / Orchard totals
GET/supplyCirculating supply breakdown

Example: quote

POST /v1/quote
{ "from": "E", "to": "ZEC", "amount": "250.0", "destination_type": "unified" }

200 OK
{
  "quote_id": "q_01H…",
  "rate": "TBA",
  "amount_out": "…",
  "fees": { "router_E": "…", "zcash_zat": 10000 },
  "expires_at_height": 0
}

Example: current response

503 Service Unavailable
{ "ok": false, "code": "NOT_LIVE",
  "message": "Zcoin mainnet has not launched." }

JSON-RPC methods

The router exposes a small JSON-RPC 2.0 interface for operators. Zcash-side calls are passed to zebrad's standard RPC (getblockchaininfo, getrawtransaction, sendrawtransaction, z_gettreestate, …).

MethodParamsReturns
ec_getinfo—Router version, heights, peers
ec_getorderorder_idOrder state and anchor
ec_listpendinglimitOrders in BUILDING/BROADCAST
ec_getanchorprooforder_idMerkle path to batch root
ec_getpoolinfo—Pool totals
curl -s -X POST localhost:7400 -H 'content-type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"ec_getinfo","params":[]}'

Error codes

CodeHTTPMeaning
NOT_LIVE503Network not launched
QUOTE_EXPIRED409Quote past expiry height
BAD_ADDRESS400Destination failed validation
INSUFFICIENT_FUNDS402Balance lower than amount + fee
LIMIT_EXCEEDED429Above per-conversion limit
ZCASH_REJECTED502Zcash node rejected the transaction
SHIELDED_PRIVATE403Shielded data can't be queried

Explorer guide

The explorer shows Ecash blocks, transactions, routed buys and their Zcash anchors. Today it shows the empty chain: height 0, no transactions.

  • Search accepts a block height, a 64-hex block hash or txid, or an address. It detects the type automatically.
  • Routed buys lists each buy with the Zcash txid that anchored it.
  • Shielded pools shows pool totals only; individual shielded balances are private by design.
  • Deep links: explorer.html#/block/0, #/tx/<txid>, #/address/<addr>.

Security model

  • Self-custody. Spending keys never leave the wallet. The router can build transactions but can't sign for users.
  • Anchoring. Routed buys inherit Zcash's proof-of-work security once anchored.
  • Zcash cryptography. Shielding uses Zcash's audited Sapling and Orchard circuits via librustzcash and orchard; Zcoin doesn't write its own circuits.
  • Audits. Router and conversion contracts will be externally audited before mainnet; reports will be published here.
  • Disclosure. Report vulnerabilities to security@electrocoin.example (placeholder).

Threat model

AdversaryCanCannot
Chain observerSee tx existence, fees, pool crossingsSee shielded amounts, senders, receivers
Malicious routerDelay or refuse orders; censorSteal funds or forge user signatures
Network observerSee your IP talking to a nodeRead shielded contents
Viewing-key holderSee history covered by that keySpend
Phishing siteTrick you into signingAnything, if you verify the domain and never paste your seed

Risks

Zcoin is pre-launch, unaudited software. Treat it as experimental.
  • Router centralisation at launch: a single operator could halt routing until additional operators join.
  • Liquidity risk on conversion: large conversions may be rate-limited or unavailable.
  • Smart-contract and implementation bugs.
  • Regulatory risk: privacy features may be restricted in some jurisdictions.
  • Price risk: E and ZEC are volatile. Nothing here is financial advice.

Tokenomics

We won't publish numbers before they're final. This table will be filled in before genesis.

ParameterValue
Total / max supplyTBA
Initial circulating supplyTBA
Issuance scheduleTBA
Allocation (community / liquidity / team / treasury)TBA
VestingTBA
Router fee rateTBA
Decimals8 (proposed)

Governance

Protocol changes will follow a public proposal process (Zcoin Improvement Proposals, "EIPs" in this project's namespace, TBA), modelled on how Zcash uses ZIPs: written proposal, public discussion, reference implementation, then activation. Treasury use, if any, will be published on-chain.

Relationship to Zcash

Zcoin is an independent project. It builds on the open-source Zcash protocol and software (MIT / Apache-2.0 licensed) and uses the Zcash network to anchor activity and deliver ZEC.

  • ZEC is the native asset of Zcash. E is the native asset of Zcoin. They are different assets.
  • Zcash development is funded by protocol-level issuance decided by the Zcash community. For background, ZIP 1014 (approved Feb 2020, effective from the Canopy upgrade in Nov 2020) split block rewards 80% to miners, 8% to independent grants, 7% to Electric Coin Co. and 5% to the Zcash Foundation for four years. See the Feed for more history.

Glossary

Anchor (Zcoin)
A confirmed Zcash transaction that commits to an Zcoin action.
Anchor (Zcash)
A note commitment tree root that a shielded spend proves membership against.
Halo 2
Recursive proof system used by Orchard; requires no trusted setup.
lightwalletd
Server that streams compact blocks to light wallets.
Note
A unit of shielded value, encrypted to its owner.
Note commitment
Public, hiding commitment to a note, stored in a Merkle tree.
Nullifier
Unique tag published when a note is spent, preventing double-spends.
Orchard
Zcash's newest shielded pool (NU5, 2022).
Router
Zcoin service that turns buys into anchoring Zcash transactions.
Sapling
Zcash shielded pool activated in 2018.
Shielding
Moving value from the transparent pool into a shielded pool.
Unified Address
A u1… address bundling multiple receivers (ZIP 316).
Viewing key
Key granting read-only visibility into shielded transactions.
Zatoshi
10-8 ZEC.
zebrad
Zcash full node implementation in Rust (Zebra).
ZIP
Zcash Improvement Proposal.

FAQ

Why route buys through Zcash at all?

It gives every buy a public, independently verifiable receipt on a proof-of-work chain, and it means Zcoin activity contributes real transactions to Zcash.

Does routing through Zcash make my buy private?

Routing anchors the buy; shielding makes it private. The anchor uses a hiding commitment so it doesn't reveal your address, but for full privacy you should hold and transact in a shielded pool.

Can Zcoin freeze my funds?

Shielded and transparent E are controlled by your keys. The router can refuse to process new orders but cannot move or freeze existing balances.

Why does the explorer show zeros?

Because nothing has launched. We'd rather show an honest zero than simulated activity.

Which Zcash pool should I use?

Orchard. It has no trusted setup and is the default for modern Zcash wallets.

References