This week we continue with our Bear Market Tactics series and follow on from last week, where we dived into how to use a Bitcoin block explorer.

This week we will investigate how to use an Ethereum block explorer and explain its account-based accounting model.

As mentioned last week, using a blockchain explorer isn’t necessarily an activity or tool that you use specifically during bear markets; however, these market downturns provide us with an opportunity to understand and master them.

Before we get into it, let’s quickly recap what a block explorer is.

What Is A Block Explorer?

Transactions on a public blockchain are visible to everyone; however, reading this raw data is exceedingly complicated from a technical perspective. Just as Google made it possible to find specific web pages on the internet, a blockchain explorer does that for the transactions on their blockchain.

As previously explained, there are several block explorers to choose from, each with unique offerings, generally focused on a specific blockchain. This week we will concentrate on an Ethereum block explorer.

Ethereum is very different from Bitcoin in that it can process smart contracts; this means that its design and accounting model needed to be different. Therefore it has adopted an account-based model vs the UTXO model of Bitcoin.

Ethereum’s Accounting Model

When designing blockchains, there are generally two types of accounting models that exist: the UTXO model and the account-based model. Bitcoin was the first blockchain and used the UTXO model; however, it possessed limitations. The main limitation was that it was harder to implement smart contracts as the UTXO model is what we call a stateless model.

Last week we explained how you could think of the UTXO model as cash in your wallet and how every UTXO represents a different note or coin that adds to the total amount in it. If you had $100 in your wallet, it could be made up of one single $100 bill, two $50’s, or one $50, two $ 20’s and a $10 and so on. Despite the different values, they still add up to $100, and each is equally spendable.

The account-based model can be thought of as the money sitting in your bank account and is a lot simpler to understand. If you have $100 in your bank account and you transfer it to a friend, your account will be debited by $100, and your friend’s account will be credited by $100. This is basically how an account-based system works. Where the UTXO system would require you to send the full amount and receive “change”, the account-based model allows you to spend your available balance partially.

Account Types

Ethereum also has two account types:

Externally-owned – controlled by anyone with the private keys

Contract – a smart contract deployed to the network, controlled by code

Both accounts have the ability to receive, hold and send ETH and other Ethereum-based tokens, and both can interact with smart contracts that are live on the Ethereum network. However, there are several key differences; according to the Ethereum Foundation, these are:

Externally-owned

  • Creating an account costs nothing
  • Can initiate transactions
  • Transactions between externally-owned accounts can only be ETH/token transfers

Contract

  • Creating a contract has a cost because you’re using network storage
  • Can only send transactions in response to receiving a transaction
  • Transactions from an external account to a contract account can trigger code which can execute many different actions, such as transferring tokens or even creating a new contract

The core concept to understand here is that externally-owned accounts initiate all transactions on Ethereum. If the receiving account is another externally-owned account, all that will happen is the balance of that account increases. If the receiving account is a contract account, its code will be triggered, and a specific action will be executed; this could be anything, from calling another smart contract to sending tokens to another address.

The account-based model is a concept that is easier to grasp when compared with the UTXO model, and it does provide several benefits over the UTXO model, including:

  • it is easier to implement smart contracts
  • transactions are more compact, and therefore there are reduced storage requirements

With an understanding of Ethereum’s accounting model, we can now dive into how to use the Ethereum block explorer.

How To Use An Ethereum Block Explorer

As with last week, there are many block explorers to choose from; we use the explorer offered by Etherscan. It is a free service that anyone can use and has an intuitive UI to visualise and interpret transactions and interact with smart contracts.

Analysing An Ethereum Block and Its Transactions

Each Ethereum block, just like Bitcoin, has a sequence number associated with it, also known as its block height; one of the most recent blocks is block 15177946.

Source: Etherscan

You can obtain a lot of information from each block. As you can see from the above, you can ascertain the block hash, its timestamp, the number of transactions contained within it, the transaction fees and block reward, the difficulty and other useful information. This can be very handy when you want to understand the specifics of any block. Etherscan also provides handy information about gas usage, base fee per gas and the amount of ETH burnt in each block since the introduction of EIP-1559.

Gas is an important concept to understand in the context of blockchain. It is what users pay to validators in order to have their transactions processed, executed and settled, essentially the “fuel” of the network. It also acts as a security measure to ensure that people only submit economically meaningful transactions and do not waste block space. As you can imagine, if it were free or extremely cheap to submit transactions, there wouldn’t be anything stopping a person from spamming the system with a vast number of transactions, causing it to grind to a halt. Therefore, gas is the cost you are willing to pay for the computational work required to process your transactions. When you are interacting with Ethereum, you set the maximum gas cost you are willing to pay (gas limit), and as long as your transaction uses less gas than that, your transaction should go through (any gas not used is returned to you). Gas in the Ethereum ecosystem is denominated in gwei, which is equal to 0.000000001 Ethereum, and for a standard transaction, you can expect to pay 21 000 gwei; the more complex the transaction is, the higher the gas cost. Each block has a total gas limit (around 30 million gwei), which can help us understand why sometimes transaction fees can be so high on the Ethereum network. People “bid” on block space as there is only a certain amount available in each block and those who pay more gas will be prioritised by the miners to have their transaction included in the block. If you look at the above example, you will see that the block wasn’t full, only 27.8% of block space was used, and so there was room for additional transactions to be included.

Once you have analysed the block, you can look at the individual transactions that have happened within each block. Etherscan conveniently classifies them and breaks them into regular transactions and contract transactions.

In the block shown above, there was a total of 101 transactions.

Source: Etherscan

You can analyse each transaction individually; however, by looking at the top few transactions included in the block, you can see some interesting information:

  • Most transfers weren’t ETH but Ethereum-based tokens; you can see this in the “Value” row
  • The 6th transaction down was a mint transaction that failed as there was an error encountered during contract execution, and the transaction was reverted
  • Someone was using their ENS name when interacting with a contract

You can look at each transaction in more detail to better understand what was happening. Some are as simple as an ETH or token transfer; however, many are more complex. Take the following transaction as an example:

Source: Etherscan

What you can see here is the following:

  • Someone used Uniswap to convert CUBE into DAI
  • It used Uniswap V2 and V3 to complete the transaction
  • To complete the transaction, they swapped the CUBE to Wrapped ETH (WETH) first and then into DAI in a total of seven token transfers
  • To initiate this transaction, they interacted with the Uniswap V3: Router 2 smart contract

Etherscan helps understand how the transaction above took place and what smart contracts were called to do so.

You can also look at the contract transactions, of which there were 40:

Source: Etherscan

In the above image, you can see that most contract transactions were contracts calling another contract. You can also see that three contracts failed for various reasons. What gets super exciting is you can look at each individual transaction and assess what contracts were called, which at points can be exceedingly complex. It allows you to visualise the concept of “money legos”, an idea we have explored before. Each contract can call another contract to perform a certain action; whether that is exchanging assets or supplying liquidity to a lending pool, each can build on top of one another and leverage their successes and abilities. Take the below contract transaction as an example:

Source: Etherscan

There were several actions that were completed by the contract at once; Etherscan makes it easy to follow the story in the Transaction Action:

  • Someone had USDC as collateral in an Aave lending pool
  • The contract withdrew that collateral from the Aave pool and swapped it for ETH on Uniswap
  • The contract then put that ETH they had just swapped back into the ETH pool on Aave as collateral

All this happened within one transaction. However, complex transactions were happening in the background to achieve this, with 12 token transfers.

Using an explorer allows you to read the story of blockchain transactions and understand them in detail. This is especially handy when it comes to reading smart contract transactions, as they can be exceedingly more complicated when compared with Bitcoin and its UTXO model.

Conclusion

The ability to use a blockchain explorer is an important one in the world of blockchain. It allows you to track your transactions and understand more about the blockchain you are using. It can provide helpful information that allows you to assess the health of the network and ensure it is operating as designed.

Next week we will continue investigating the Ethereum block explorer, using it to assess network health and other interesting types of analysis. If you have any questions or have trouble using the explorer, please feel free to reach out and ask us questions. We always look forward to chatting with our readers. Otherwise, please feel free to share this article if you know anyone who is interested in learning more about using a block explorer.

If you are interested in staying up to date, please subscribe to our newsletter at etherbridge.co

This is not financial advice. All opinions expressed here are our own. We encourage investors to do their own research before making any investments.