Scaling Ethereum - The Daily Gwei #329

Let's onboard the world.

The layer 2 rollout on Ethereum is well and truly underway now with over $1 billion locked in various protocols. Though we really are just at the very beginning of the adoption (and rollout) cycle for layer 2’s and there’s plenty of work and innovation left to do across the entire stack. Probably the most important work is ensuring that we can lower the fees of using these layer 2’s by as much as possible (you can see the current costs here).

One thing that I’ve seen many people confused about lately is the fact that a token swap on Arbitrum or Optimism still costs somewhere from $3 to $6 leading people to believe that this is the best layer 2 has to offer - but, of course, this is not the case! The really interesting thing about layer 2’s is that they work off of economies of scale which means the more transactions that are processed, the cheaper the individual cost per transaction. To give a very basic example of how this works: imagine that each hour a layer 2 is posting a batch of transactions to layer 1 and it costs $500 in gas fees per batch. Now, if there were only 100 total transactions in that hour (let’s say they were all Uniswap trades for simplicity), then each transaction would’ve had to pay a $5 fee (at minimum). But what if there were 1,000 transactions in that hour? Well each transaction would’ve only had to pay $0.50 in fees. Of course, it’s more complex than this and there are limits as a layer 2 doesn’t have unlimited scalability (its limited by layer 1), but I still think this basic example illustrates the point quite well. Do also note that both Arbitrum and Optimism currently have transaction limits in place as well.

There are many different layer 2 constructions that come with their own trade-offs and trust assumptions. For example, StarkWare’s Validium construction allows for greater scale because it stores the data off-chain instead of posting it on-chain though this comes with the trade-off that funds can be lost if this data becomes unavailable and/or users can be censored. Another example is Matter Labs’ zkPorter technology which promises to be interoperable with zkRollups while achieving 20,000+ TPS (this constructions isn’t on mainnet yet though). Of course, we’ve really only scratched the surface of these types of scaling solutions and I’m sure we’ll see many more flavors as the years go on.

Let’s not forget about all of the scaling improvements coming to layer 1 over the next few years that will greatly enhance the layer 2 ecosystem. The most impactful of those is ‘data sharding’ as this effectively increases the “storage space” for layer 2’s enabling them to scale to potentially 100’s of thousands, if not millions, of transactions per second - all while still inheriting Ethereum’s best-in-class security and decentralization. Other potential improvements (that are just as important!) include increasing the gas limit when it’s considered safe to do so, state expiry/statelessness, ‘snarkifying’ the base layer and more.

The future of scaling Ethereum is very bright with plenty of exciting developments at layer 2 (and layer 1!) in the pipeline. I remember at the start of this year I said that it would be “the year of layer 2” and it seems it so far has been (at least in terms of projects coming to mainnet). Over the next few years, we’re going to have a massive amount of adoption for these layer 2’s that will make even the most bullish Etherean’s heads spin - and I’m so ready for it.

We’re going to scale Ethereum for the world while preserving the critical properties of decentralization and security - what a beautiful world that is going be.

Have a great day everyone,
Anthony Sassano

Enjoyed today’s piece? I send out a fresh one every week day - be sure to subscribe to receive it in your inbox!

Join the Daily Gwei Ecosystem