Anyblock is now proudly part of Blockdaemon - read the announcement in our blog
May 4, 2020

How to do Blockchain Data Science with Metabase using a real world example


Icon article header
Blockchain Dashboards with Metabase query editor

Why use Metabase for blockchain analytics?

Here at Anyblock Analytics, we choose Metabase as our primary blockchain visualization tool because it enables business users to answer their questions themselves, rather to wait for precious developer time. This is possible because of the simple Metabase point and click editor so that no SQL query language needs to be used (but it can).

The other great feature is the ease of sharing Metabase blockchain dashboards publicly or with the respective shareholders. The link to do so is generated with two clicks and the graphs can just as easily be embedded into websites or users’ internal applications.

What is Metabase in general?

“Metabase is an open source business intelligence tool. It lets you ask questions about your data, and displays answers in formats that make sense, whether that’s a bar graph or a detailed table.
Your questions can be saved for later, making it easy to come back to them, or you can group questions into great looking dashboards. Metabase also makes it easy to share questions and dashboards with the rest of your team.”

Source: Metabase Website

How to create a Metabase blockchain dashboard?

1. Start: Ask a question 

Metabase Header


2. Choose the way of asking your question

  • Simple question is meant for simple requests of data (generally not really helpful with our blockchain data model)
  • Customized questions are recommended if you want to easily filter and summarize your data (recommended for beginners / business users)
  • Native Queries has to be written in SQL which requires at least basic knowledge in that language (recommended for advanced users / developers
Metabase Questions

3. Pick your “starting data” (meaning to choose our supported blockchain as the source, see our list of networks on our Network Status Page)

Hint: It is also possible to pick previous questions as data for your next question (Find them here: “Saved questions”)

4. Now you can start to filter, summarize and sort your data (the following screenshot shows the editor for customized question)


5. After you’ve picked your data, you are now able to visualize the results

6. Configure your visualization in  different formats 

Result  Visualization
Result Visualization

Example: Blockchain analytics to create Metabase dashboard for The Energy Origin – TEO


At the beginning it is essential to be aware of

  • what are the objectives of your dashboard,
  • what you will require to build your dashboard,
  • and how you will achieve these objectives.

The goal of the TEO dashboard was to provide a visualization of the events happening on the TEO smart contract and to analyze them as detailed as possible without knowing the source code or any documentation. General information about the project is available on the website of The Energy Origin – TEO.

The first step is to determine the blockchain on which the project runs. TEO uses the Energy Web Chain (EWC) of the Energy Web Foundation. The EWC is one of over 22 different blockchain in the Anyblock Index, which contains many public blockchains but is also available for enterprise consortia blockchains such as this one.

After the address of TEO had been identified, it is necessary to find out if the ABI for this address is available, as this represents the only way to be able to see what is happening. The Anyblock Index uses the contract’s ABI to translate the hexadecimal raw blockchain data into human-readable event names and formats numbers with the right decimal format.


Once the two requirements, address and ABI, are in place, all events taking place on TEO can now be analyzed and visualized.


Data  Vizualisation


This custom question leads to the following diagram by visualizing the outcoming data.


Data Diagram


After this time-series chart of all events is done, two fundamental questions immediately come to mind: What do these events represent and who are the addresses which are executing these events?


To answer this question, the next challenge is: How can the individual events be analyzed? This required decrypting the individual certificates of the events, which was only possible as a SQL question, as the parameters are saved in an array in our SQL blockchain data model:


Blockchain Data Model


Using this query, it was now possible to filter the number of unique addresses per event via Metabase. For example, it was possible to identify the unique addresses that send out events on TEO.


Metabase Stats


Finally, all events are shown in a time-series stacked line chart, and also the unique addresses behind the different events are displayed on the dashboard. The viewer is therefore provided with aggregated information about the entire timespan of the smart contract activity, and an additional table about the latest events on TEO provides real-time monitoring capabilities.

Link to the continuously updated online dashboard.



Blockchain Dashboard


Our dashboards can just as easily include the possibility to drill-down on the data with filters.

This enables for example to limit the data shown in the dashboard to a certain interval of dates, show the activities of individual user addresses or check the status of certain transactions. You can find some examples for our interactive dashboards on our website.

We hope you found this little tutorial on blockchain data science with Metabase useful.

If you have any questions about blockchain analytics and data science in general, want to exchange some tricks working with Metabase or would like insights into a particular smart contract – we’d love to hear from you!

Looking to create an Anyblock account?

Takes seconds and it's free!

Interested or questions?


Freddy Zwanzger
(Co-Founder & Chief Data Officer)
+49 6131 3272372


Recent Posts

Anyblock Multi-Chain REST API for RPC & Data

Anyblock Multi-Chain REST API for RPC & Data

Anyblock REST API endpoints for RPC & data are a fast and reliable solution, which is available for more than 20 blockchains and does not require running your own node. You can view the list and description of all our endpoints in the Anyblock REST API docs.

In this article, you will find general information on Anyblock API and examples showing how to interact with it.

November Twitter Summary

November Twitter Summary

Hey there, developers! Anyblock Twitter Summary for the month of November is here.  Read it here or check out our Twitter account.Enjoy it!  Or just follow us directly if it's easier for you. Happy tweet-reading! :)🤔 Most people believe they need to operate a...

This is the beginning of a new chapter…

This is the beginning of a new chapter…

We are super excited to announce that Anyblock Analytics GmbH will be spearheading the expansion of Blockdaemon Inc. in Germany! The corresponding contracts have been signed last week and closing is expected shortly as well.

Pin It on Pinterest