Electrum Server
An index that answers wallet queries about addresses and history, so a wallet need not hold the chain.
Basically
An Electrum server keeps a searchable record of Bitcoin transactions for your wallet. It lets a lightweight wallet check balances and past payments without running a full Bitcoin node.
Key Takeaways
- An Electrum server indexes the Bitcoin blockchain by address, so lightweight wallets can look up balances and transaction history without scanning the entire chain. It sits between a full node and wallet clients.
- Three major implementations serve different needs: ElectrumX (Python, feature-rich), Fulcrum (C++, fastest queries), and electrs (Rust, smallest disk footprint). Each trades off sync speed, storage size, and query performance.
- Privacy is the core concern: a public Electrum server learns all of your addresses, your full transaction history, and your IP address. Running your own server eliminates this leak entirely, which is why self-hosted setups are recommended for serious Bitcoin users.
What Is an Electrum Server?
An Electrum server is middleware that connects a fully validating Bitcoin node to lightweight wallet clients. It reads every block from the node, extracts transaction data, and builds an index organised by address, technically by script hash. Your wallet queries this index to check its balance or look up past transactions instead of scanning the entire blockchain itself.
A wallet without an Electrum server has two options: run its own full node and rescan the blockchain, which is slow and resource-heavy, or trust a third-party API with limited verification. The Electrum protocol offers a middle path by giving the wallet fast, indexed lookups while still verifying transaction inclusion through Merkle proofs. This works in a similar way to an SPV client.
The Electrum protocol was originally designed for the Electrum desktop wallet but has since become a de facto standard. Wallets like Sparrow, BlueWallet, and many others support connections to Electrum-compatible servers. This architecture is now one of the most widely deployed patterns for Bitcoin wallet infrastructure.
How It Works
The Electrum server architecture has three layers. A Bitcoin full node validates and stores the blockchain, the Electrum server indexes it, and wallet clients query the index over the Electrum protocol.
Blockchain Indexing
The server connects to a Bitcoin Core node via RPC when it starts and processes every block from the genesis block forward. It builds an index entry for each transaction output, organised by the output's script hash.
The script hash approach is address-type agnostic and works identically for P2PKH, P2WPKH, P2TR, and all other address formats. Your wallet computes the same script hash for any address it controls and queries the server for matching transactions.
The Electrum Protocol
Clients communicate with servers using JSON-RPC over TCP/SSL connections. The standard ports are 50001 for TCP and 50002 for SSL/TLS, with modern clients exclusively using encrypted connections. The protocol supports both request-response queries and subscriptions that push updates when state changes.
Key protocol methods support queries for blockchain data and subscriptions to changes. These methods let your wallet request information and receive updates through the same protocol.
The subscription model is particularly important for payment detection. Your wallet calls blockchain.scripthash.subscribe, and the server returns the current status before pushing a notification whenever a new transaction involving that script hash appears. This lets your wallet detect incoming payments in real time without polling.
SPV Verification
Electrum clients do not blindly trust the server for confirmed transactions. The client requests a Merkle branch via blockchain.transaction.get_merkle when the server reports a transaction as confirmed. This proof links the transaction to a block header that the client has independently validated as part of the longest proof-of-work chain.
The server is trusted for mempool transactions because no SPV proof exists for unconfirmed transactions. A malicious server can also "lie by omission" by withholding transactions from history results. Running your own server eliminates both risks.
Server Implementations
Three open-source implementations dominate the Electrum server ecosystem: ElectrumX, Fulcrum, and electrs. Each has distinct trade-offs in sync speed, storage size, and query performance.
ElectrumX
ElectrumX is the original Electrum server implementation, written in Python. The spesmilo team, the Electrum wallet developers, now maintains it after the original author dropped Bitcoin support. ElectrumX stores enough data in its index to answer most client queries without reaching back to Bitcoin Core, making it efficient for serving many concurrent clients.
Fulcrum
Fulcrum is a high-performance C++ implementation that delivers the fastest query response times of any Electrum server. It stores the full 32-byte script hash for each entry, with no truncation, eliminating false positives. Benchmarks from Sparrow Wallet show that it loads wallet history 20 to 30 times faster than ElectrumX.
electrs
electrs is a Rust implementation optimised for minimal resource usage. Unlike ElectrumX and Fulcrum, it does not require txindex on Bitcoin Core and maintains the smallest index of any implementation. The trade-off is that it stores only block heights per script hash and must reparse raw blocks at query time, resulting in slower responses for wallets with large transaction histories.
Privacy Considerations
The privacy model is the most important thing to understand about Electrum servers. A public Electrum server operator learns all of your queried addresses, your full transaction history, and your IP address when you connect.
The server can reasonably conclude that all queried addresses belong to the same entity. HD wallets derive many addresses from a single seed, so the server effectively learns your entire financial picture.
Compact block filters (BIP 157/158) use a fundamentally different privacy model: the client downloads filter data and performs matching locally, so the server never learns which addresses interest the client. The trade-off is that compact block filters require more bandwidth and are slower for initial sync. The Bitcoin privacy analysis provides a deeper comparison.
Why Running Your Own Server Matters
A personal Electrum server is the recommended configuration for users who take self-custody seriously. Your wallet connects to your own server backed by your own full node, giving you private lookups and protection against a server withholding transactions. You also avoid trusting an external server for mempool transactions.
A typical self-hosted setup runs Bitcoin Core alongside an Electrum server on the same machine, often a Raspberry Pi or small server. Node distribution platforms like Umbrel, RaspiBlitz, and Start9 bundle these components together with one-click installation. These bundles make the setup accessible to non-technical users.
The self-custodial vs. custodial wallets comparison and the Bitcoin node implementation comparison provide more context. They cover the trade-offs between self-hosted and third-party infrastructure.
Desktop and Mobile Wallets
Lightweight wallets are the primary use case for Electrum servers. Wallets like Sparrow, Electrum, and BlueWallet connect to an Electrum server to fetch address balances, build transaction histories, and broadcast signed transactions. You can run a feature-rich wallet without maintaining hundreds of gigabytes of blockchain data on your device.
Watch-Only Monitoring
Watch-only wallets use Electrum servers to monitor addresses without holding private keys. Cold storage monitoring commonly uses this pattern: you keep keys on a signing device while tracking balances through a watch-only wallet connected to your own Electrum server.
Multisig Coordination
Multisig wallets rely on Electrum servers to track UTXO state across multiple signers. Each cosigner can run their own wallet pointed at a shared or personal Electrum server to independently verify the multisig wallet's balance. Cosigners can also construct partially signed transactions using PSBTs.
Block Explorer Backends
Customised forks of electrs power some of the most popular block explorers. Blockstream.info uses a fork of electrs as the backend for its Esplora explorer. mempool.space runs a modified version for its mempool visualisation and transaction lookup service.
Trust and Privacy Trade-offs
A public Electrum server requires you to trust the operator not to log, sell, or exploit the address and transaction data they inevitably collect. Even well-intentioned operators may be compelled to share logs with authorities. Running your own server is the only mitigation that fully addresses this risk.
Server Integrity
A malicious Electrum server can withhold transactions from query results, known as lying by omission, causing a wallet to display an incorrect balance. The server cannot forge transactions because SPV proofs prevent this for confirmed transactions, but it can hide incoming payments. Connecting to multiple servers or running your own eliminates this risk.
Resource Requirements
An Electrum server requires a fully synced Bitcoin Core node using 600+ GB, plus the server index at 30 to 100+ GB depending on the implementation. Initial indexing can take hours to days. The privacy trade-off of using a trusted public server may be acceptable if you lack the hardware or bandwidth to maintain this infrastructure, especially when combined with Tor for IP-level privacy.
Phishing via Server List
Attackers have previously added malicious servers to public Electrum server lists that returned crafted error messages containing phishing links. These messages appeared in wallet interfaces and tricked users into downloading malware. Modern Electrum clients have mitigated this by filtering server messages, but the episode illustrates the risks of connecting to untrusted infrastructure.
This glossary entry is for informational purposes only and does not constitute financial or investment advice. Always do your own research before using any protocol or technology.