Danksharding: Scaling Ethereum

BitGo Editor
Official BitGo Blog
10 min readFeb 16, 2024

--

  • Proto-danksharding is the first upgrade in danksharding.
  • Layer 2 transaction fees will drop by 10x due to L2 being able to use blobs. Blobs contain executed transaction data and are attached to blocks.
  • Ethereum has removed traditional sharding from the roadmap. Putting rollups as the key to Ethereum’s future success.
  • Ethereum will become a data availability layer, allowing hundreds of rollups to scale with full danksharding.
  • Validators will no longer be able to create blocks, but they will increase their share of MEV profits.

Proto-Danksharding Explained: Scalability for Ethereum

Concerns surrounding Ethereum’s scalability and associated transaction cost fluctuations have rightly garnered increased attention. Frustrated by the high cost of transactions on Ethereum, retail users are exploring alternative blockchains with lower fees. However, innovative scaling solutions such as Layer 2 blockchains (L2) and rollups help ease Ethereum’s high fees. Danksharding will allow Ethereum to scale to millions of users.

Importance of Rollups

Rollups, known as Layer 2, are off-chain scaling solutions that operate on top of the Ethereum network. In a rollup, transactions are essentially rolled up, hence the name, into collections of transactions. Rollups can be compared to sending a letter using the postal service. Just as sending multiple letters individually to one address racks up postal fees, sending individual transactions on Ethereum increases the load on the network. However, with a single package or “rollup proof” letters (transactions) can be packaged together, reducing fees significantly.

Rollups submit their aggregated transactions back to their corresponding Layer 1. Rollups have the capability to integrate with any blockchain that permits unrestricted data posting. In this discourse, Ethereum rollups will be the focal point, as Ethereum plans to scale through rollups. By using Ethereum as a data availability layer, execution can move off of Ethereum and into the rollup. Anyone can check the state by reconstructing it and determining if the state is valid. Through reliance on Layer 1 for consensus and settlement, rollups benefit from the inherent security guarantees of the Ethereum blockchain. The prevalent rollup architectures are optimistic and zero-knowledge (ZK) rollups.

This process happens under the hood and is abstracted from the user.

Rollups have already achieved massive reductions in cost. Scaling solutions such as Optimism and Arbitrum optimistically execute all transactions by assuming the data is valid. Users can submit fraud proofs to safeguard against malicious activities, providing absolute certainty that tampering or invalid state transitions within the rollup have occurred. Submitting fraud-proof rewards the user with a portion of the validator’s deposit. As more rollups come online, they fight for block space with L1 users when sending bundles back to Ethereum. To combat this and allow L2 solutions to scale, Ethereum will soon launch its first upgrade into danksharding.

Scalability

The blockchain trilemma, coined by Vitalik Buterin, is a core trade-off in blockchain design. In which blockchains have three main features: scalability, security, and decentralization. You can only pick two out of three. In Ethereum’s case, they chose decentralization and security, which limited scalability. Ethereum’s commitment to decentralization and security is evident through its ability to participate with consumer-grade hardware and its validator pool exceeding 900,000. However, this comes at the cost of scalability. With lower hardware requirements and architectural designs, many nodes having to communicate with each other severely limits throughput.

Scalability is the process of handling additional requests without becoming overwhelmingly expensive or unusable. Interacting with smart contracts requires a much higher computational load than just transferring native Ethereum tokens. Ethereum could have a theoretical max of 119.04 transactions per second (TPS) with basic native transfers. Ethereum averages 13 TPS because smart contract interactions may be equivalent to 10 or more native Ethereum transfers. However, the theoretical 110 is impossible in practice because EIP-1559 targets 50% block utilization. In its current form, Ethereum needs to scale better than competitors like Solana. L2s can achieve high throughput and help Ethereum scale while building out danksharding.

On the other hand, blockchains built on more demanding hardware and limiting nodes can generally scale more easily. With danksharding and maintaining its commitment to accessible hardware, Ethereum will eventually be able to scale via rollups. Scalability is a significant challenge, as adoption cannot occur if blockchains become unusable with increased traffic.

What is Sharding?

One of the solutions for creating a lower latency environment and higher throughput chain is sharding. Sharding is a scaling solution used in blockchain to increase performance by distributing the workload of the network. The idea is to have multiple shards (chains) executing transactions, each handling a specific network portion. Inside each shard, validators are responsible for executing their share of the chain.

The network can handle more transactions per second by executing transactions in parallel. Additionally, data retrieval is significantly faster as each shard is only responsible for its share. Sharding provides additional benefits to the network through enhanced fault tolerance. If one shard goes offline, the entire network will not shut down and can still operate on other shards.

However, sharding has challenges in maintaining security by distributing the network. For example, if 100 validators are broken up into ten shards, each shard may be vulnerable to malicious attacks due to validators being spread out. Additional sharding concerns are moving data between shards and rebalancing shards, which may cause downtime or inconsistency.

What is DankSharding?

Despite initial enthusiasm for sharding as a scalable solution for Ethereum, concerns surrounding security, cross-shard communications, and complexity cause significant hurdles as major overhauls need to be made to Ethereum’s architecture. As complexity rose, the Ethereum Foundation removed sharding from the roadmap and replaced it with danksharding. Danksharding allows Ethereum to scale via rollups by using blobs.

Blobs are a new transaction type that contains executed transaction data from the rollup. As blob-containing blocks carry more data, this will increase storage requirements for nodes. The Ethereum Foundation is evaluating the optimal amount of space; currently, the specification is 768kb, for blob transactions. Since each blob is a maximum of 128 kb, this equates to six blobs per block. As the mempool for blobs will employ mechanics similar to EIP-1559, the average blobs per block will be three. Long-term upgrades with data availability sampling will allow nodes to download a portion of the blob but still verify all data is correct. With full danksharding, Ethereum can scale and handle hundreds of rollups and process millions of transactions per second.

What is Proto-DankSharding?

Proto-Danksharding, EIP-4844, was named after Ethereum researchers Protolambda and Dankrad Fiest. While danksharding is years from reality, proto-danksharding can help Ethereum scale now. After several more testnet upgrades, proto-danksharding will be scheduled for release sometime in early Q1 2024.

Proto-Danksharding will be a significant upgrade to user experience on L2s. For example: a transaction on the mainnet that costs $20–25 to execute may cost 40 cents on a rollup. After the network upgrade, fees should be reduced by another 10x as CALLDATA will not be used to store L2 data. Rollups will finally be more competitive with alternative Layer 1’s with higher throughput. Even though proto-danksharding will decrease L2 fees and promote higher use, this will not increase Ethereum’s TPS.

Proto-DankSharding Mechanics

Proto-danksharding introduces blobs, which contain data for executed transactions. These blobs are attached to the block alongside a posted cryptographic commitment. This commitment results from a polynomial fit to data at a given point, and these data points are generated randomly from the KZG ceremony.

The Ethereum Foundation describes the KZG ceremony as:

  1. Participant 1 chooses a random number (eg 5.) and then runs a computation on it.
  2. The output from that computation is passed to Participant 2, where they repeat Step 1 with their secret input (e.g. 3) and mix it with the output from the 1st Participant (eg. 5x3=15).
  3. This repeats until there are sufficient participants, at which point the last output in the sequence becomes the final output.

Anyone who wants to verify the data can recompute the commitment by re-executing the transactions and comparing the results. If the result matches the computation, then the data is valid. The numbers from the KZG ceremony have to be random. Otherwise, someone could generate a new polynomial at a given point and change the data, and the result would still be valid.

Source: YouTube

The primary use case for blobs is to save data storage costs by L2s and lower fees with a separate fee market. However, most rollups only need to store data temporarily on Ethereum. Optimistic rollups need up to seven days to ensure that fraud has not occurred. Temporary storage ensures state bloat does not become an issue, and blobs will be available from third parties that store all historical data. Even though blobs will not be accessible after 4096 epochs, roughly 18 days, the KZG commitment will remain visible, leaving a remnant that can still be used to verify the blobs.

Ethereum Foundation explains proto-danksharding as

Right now, rollups are limited in how cheap they can make user transactions by the fact that they post their transactions in CALLDATA. Using CALLDATA is expensive because all Ethereum nodes process it and live on-chain forever, even though rollups only need the data for a short time. Proto-Danksharding introduces data blobs that can be sent and attached to blocks. The data in these blobs is not accessible to the EVM and is automatically deleted after a fixed period (1–3 months).

By not using CALLDATA, rollups can avoid paying four gas for zeroed bytes or 16 gas per non-zeroed byte. Blobs will cost one gas per byte, reducing gas costs significantly. These savings are the primary reduction and benefit of rollups.

When proto-danksharding goes live, every node will have to download each blob. To have true rollup scalability, full danksharding will allow nodes to download portions of the blob data but can still verify the entire blob. Data availability sampling will be introduced later in full danksharding but is a critical mechanism for validators to verify large amounts of blobs efficiently and confidently. Having a validator randomly sample random data points and create a proof means the validator does not have to check the entire blob. If any data is missing, then the blob will have a different commitment.

Erasure coding is introduced to cover all attack vectors when sampling data. Erasure coding encodes blobs so that if half the blob is broadcasted, anyone in the network can reconstruct it. By using polynomial commitments, anyone can easily prove that data is valid. This would protect the network if a malicious sequencer were to withhold between 1 and 49% of blob data.

Proposer Builder Separation

Currently, Layer 2 solutions take up 10.5% of the block space. Decoupling blobs from the mempool takes even more stress off the network. Blobs will use a different mempool, creating an additional hurdle for block builders. Currently, block builders compete against one another by leveraging transaction selection and sequencing strategies to optimize block composition to capture the highest possible economic value. After proto-dank sharding goes live, block builders must order two pools and manage gas limits on each.

Danksharding will also include proposer-builder separation (PBS). Ethereum validators are currently building and broadcasting blocks to the network. Validators can look into the public mempool and take the highest fee transactions, or they can opt-in to MEV-boost and take pre-built blocks with an added tip. Accepting maximum extractable value (MEV), blocks give validators 2.83x the block reward than if they used public mempools.

PBS takes this further, allowing less censorship and higher validator returns with higher MEV sharing. After PBS goes live, validators will not be able to create blocks. They will only be able to receive blocks from a block builder. Also, validators cannot look into the block, and they can only see which has the highest fee. Because of this, MEV will be incentivized to give validators a higher split of the MEV to have their block chosen.

Looking Ahead

Although danksharding is years away, Ethereum can scale now with proto-danksharding. Rollup data storage costs will plummet as CALLDATA will no longer be used. By using temporary storage in the form of blobs, Ethereum will improve transaction fees by at least tenfold. Even though end users will significantly benefit on L2s from reduced fees, this may have little to no impact on Ethereum’s transactions.

Blobs containing executed transaction data from rollups can be attached to each block. The EVM cannot access these blobs and they are pruned every 4096 epochs. According to Ethereum’s documentation, blobs will start at one blob per block and scale up to 64 with full danksharding. However, recent tests have shown core developers debating between a maximum of four to six blobs per block. Cryptographic “commitments” attached to the blobs allow for seamless data verification without needing to parse through it. These commitments also stay after the blob is removed from the network. Blocks builders will become more specialized as validators can no longer create their own. Validators will choose the highest value block as they can no longer see into each block, indirectly increasing MEV share.

The much-anticipated Proto-DankSharding upgrade is slated for rollout on the Ethereum mainnet in Q1 2024. It was successfully deployed to the Goerli testnet on Jan 17, 2024; other testnets will follow shortly. Even though sharding has been removed from the roadmap, proto-danksharding is a much-needed upgrade for Ethereum L2s to remain competitive against lower-cost L1s.

To learn more about BitGo’s Ethereum offerings, and how Danksharding will affect our Ethereum wallets, connect with us.

©2024 BitGo Inc. (collectively with its affiliates and subsidiaries, “BitGo”). All rights reserved. BitGo Trust Company, Inc., BitGo Inc., and BitGo Prime LLC are separately operated wholly-owned subsidiaries of BitGo Holdings, Inc., a Delaware corporation headquartered in Palo Alto, CA. No legal, tax, investment, or other advice is provided by any BitGo entity. Please consult your legal/tax/investment professional for questions about your specific circumstances. Digital asset holdings involve a high degree of risk and can fluctuate greatly on any given day. Accordingly, your digital asset holdings may be subject to large swings in value and may even become worthless. The information provided herein is not intended for distribution to or use by, any person or entity in any jurisdiction or country where such distribution or use would be contrary to law or regulation. BitGo is not directing this information to any person in any jurisdiction where the publication or availability of the information is prohibited, by reason of that person’s citizenship, residence, or otherwise.

--

--

The leader in institutional digital asset custody, trading, and finance. Learn more at bitgo.com