The Ethereum Shanghai Upgrade represents a monumental shift for the network and its stakeholders. This guide provides a comprehensive overview of the upgrade's mechanics, focusing specifically on the new ability to withdraw staked ETH from the Beacon Chain.
Understanding the Shanghai Upgrade
The core feature of the Shanghai upgrade is enabling withdrawals for the approximately 16.45 million ETH that has been locked in staking on the Beacon Chain since December 2020.
A critical distinction exists between two types of withdrawals:
- Partial Withdrawals: Stakeholders wishing to only withdraw their accumulated consensus rewards can do so quickly, without any queue. This means the total rewards earned over the past two years (approximately 1 million ETH) can be withdrawn almost immediately.
- Full Withdrawals: Stakeholders who wish to exit a validator node entirely—withdrawing the full 32 ETH stake plus rewards—will enter an exit queue. This process is rate-limited to protect network security. With over 500,000 active nodes, the protocol allows a maximum of 1,800 validators (57,600 ETH) to exit per day.
The Role of Testnets: Zhejiang and Sepolia
Before deploying on mainnet, the withdrawal functionality was rigorously tested on public testnets.
- Zhejiang Testnet: Launched on February 1st, this testnet allowed users to simulate the entire process of withdrawing staked ETH, providing valuable practice for validators.
- Sepolia Testnet: This testnet underwent its Shanghai upgrade on February 28, 2023, serving as another critical testing environment.
These tests confirmed that once withdrawals are enabled, the network automatically processes partial withdrawals, scanning validators and distributing rewards to those with the correct credentials at a rate of 16 validators per block.
The Two Types of Withdrawal Credentials
The upgrade introduces a clear framework for two types of withdrawal credentials, which are crucial for understanding the withdrawal process.
- 0x00 Credentials: Funds remain locked in the validator account until a withdrawal address is provided. This was the standard for early stakers.
- 0x01 Credentials: This new type allows for automatic withdrawals from the consensus layer. All withdrawals now require a 0x01 credential.
A key operational change is the rate-limiting of the credential switching process. The operation to add a 0x01 withdrawal credential is limited to 16 per block. Furthermore, a withdrawal address can only be set once and is immutable thereafter.
How to Perform a Partial Withdrawal (Claiming Rewards)
Partial withdrawals are designed to be automatic and effortless for validators who are active and have an effective balance capped at 32 ETH.
Any balance earned as rewards that exceeds 32 ETH does not increase the validator's principal or its weight on the network. Therefore, this excess is automatically extracted as a reward payment every few days. Crucially, this process is initiated entirely on the consensus layer and requires no gas (transaction fees). Validators do not need to take any action aside from having initially set a withdrawal address.
It is important to note that you cannot extract a custom amount; the protocol automatically withdraws everything above the 32 ETH stake.
How to Perform a Full Withdrawal (Exiting a Validator)
Exiting a validator node to retrieve your full stake and rewards is a more involved, manual process.
- Set a Withdrawal Address: Before any funds can be moved, you must provide a withdrawal address (0x01 credential) if you haven't already.
- Sign a Voluntary Exit Message: Unlike partial withdrawals, a full withdrawal cannot happen automatically. You must sign and broadcast a "voluntary exit" message using your validator key. This is done through your validator client, submitted to your beacon node, and also requires no gas.
The status of a validator on the Beacon Chain changes during a full exit:
- Active Ongoing (Before exit)
- Active Exiting (After triggering exit)
- Withdrawal Possible (After exit is complete)
- Withdrawal Done (After funds are withdrawn)
👉 Explore more strategies for managing your validator exit
The Technical Mechanics of withdrawals
1. Automated Validator Scanning
The entire withdrawal process is automated by the consensus layer in a continuous cycle. It does not require user input to determine if an account should initiate a withdrawal.
When a validator is scheduled to propose the next block, it builds a withdrawal queue of up to 16 eligible withdrawals. The protocol starts from validator index 0 and sequentially checks each account against the eligibility criteria, adding it to the queue if it qualifies. This scanning process continues indefinitely from where the previous block left off.
2. The Eligibility Check
For each validator scanned, the protocol asks a series of questions to determine if a withdrawal should be triggered:
- Has a withdrawal address been provided? If not, the account is skipped.
- Has the validator exited and become withdrawable? If yes, a full withdrawal is processed, transferring the entire balance to the withdrawal address.
- Is the effective balance at its max of 32 ETH? If the account has a withdrawal credential, is not exited, and has rewards waiting above 32 ETH, a partial withdrawal is processed.
3. The Gas-Free Advantage
This automated, consensus-layer method means stakers never have to manually submit a transaction to request a withdrawal. This eliminates the need for gas and ensures withdrawals do not compete for scarce execution layer block space.
Withdrawal Timing and Processing Rates
With a capacity of 16 withdrawals per block, the network can process up to 115,200 validator withdrawals per day (assuming no missed blocks). Validators without eligible withdrawals are simply skipped, speeding up the scanning process.
The time to process all withdrawals depends on the total number of validators in the queue. As the network grows, the time to complete a full cycle of scans will increase accordingly.
Frequently Asked Questions
How often will I receive my staking rewards from a partial withdrawal?
The network automatically scans all validators for excess rewards continuously. The frequency with which your specific validator is processed for a partial withdrawal depends on the total number of active validators and the rate of block production. With hundreds of thousands of validators, it may take several days for the scanning cycle to reach your validator and process its rewards.
Can I withdraw my staked ETH to a centralized exchange?
Yes, most major centralized exchanges that offer Ethereum staking will support withdrawals to user accounts on their platform. You will typically need to provide a withdrawal address generated by your exchange account. Always confirm the specific instructions and support status with your exchange before initiating any withdrawal.
Is there any risk to my funds during the withdrawal process?
The withdrawal mechanism is a core part of the Ethereum protocol upgrade and has been extensively tested. The process itself is designed to be secure. The main risks involve user error, such as incorrectly setting a withdrawal address or mishandling validator keys during the exit process. Always follow official guides and double-check all commands and addresses.
What happens if I don't set a 0x01 withdrawal credential?
If you only have a 0x00 credential, your funds (both stake and rewards) will remain locked in the validator account. You will not be able to perform any withdrawals until you successfully execute a BLS to execution change operation to switch your credentials to the 0x01 type.
Will the ability to withdraw cause a massive sell-off of ETH?
While some sell pressure is expected as early stakers access their locked ETH and rewards, analyses suggest it will be manageable. Many stakers are long-term believers in Ethereum and may choose to restake or hold. Furthermore, the daily withdrawal limit acts as a circuit breaker, preventing a sudden, massive outflow of ETH from the beacon chain.
Can I withdraw a custom amount, like just 10 ETH?
No, the protocol does not allow for custom withdrawal amounts. You can only perform two types of automated actions: a partial withdrawal of all rewards above your 32 ETH stake, or a full withdrawal of your entire validator balance (stake + rewards). For more flexible liquidity options, you might consider view real-time tools built on top of the protocol, like liquid staking tokens.