---
title: "MetroBlocks: a block-based metronome"
description: "A browser metronome that describes a song as blocks with their own tempo and time signature, played live or exported as a WAV click track."
date: 2026-01-26T13:34:28+01:00
lastmod: 2026-10-16T18:58:52+02:00
url: https://klimek.link/projects/metroblocks/
author: "Marcin Klimek"
source: https://klimek.link/projects/metroblocks/
---

# MetroBlocks: a block-based metronome

An ordinary metronome has one tempo, but real songs have sections, so **MetroBlocks** describes a song as a list of blocks:

- lead-ins, for example two 4-bar count-ins with different click sounds;
- song blocks, each with a name, a number of bars, a tempo, a time signature, a click sound and an optional accent grouping for odd meters, such as 3+3+2.

A colour-coded timeline shows the structure and the length of the song, highlights the block that's playing and starts playback from any block you click.

*Diagram: Schematic of the MetroBlocks screen, not a screenshot*

For playback I used the Web Audio API, with all the clicks scheduled ahead of time. To get a WAV click track, you can render the same song offline with `OfflineAudioContext` and save it. Songs are saved in the browser automatically and can be exported and imported as JSON. It's a static web app with no server, and the interface is in Polish.

**[Open MetroBlocks →](/metroblocks/)** · [Source on GitHub](https://github.com/marcinklimek/metro)

Source: https://klimek.link/projects/metroblocks/
