If you’re an avid music listener, you might have wondered how your music tastes and listening habits changed over time. Maloja is a lightweight, open-source music scrobbler for your homelab. It comes with powerful features that offer flexibility while removing the unnecessary cruft that comes with other alternative services.
Features
- Ultra-lightweight and doesn’t rely on third-party services
- Highly customizable with the ability to select custom images
- Supports custom tagging schemas for your music database
- Supports granular associations with artists and releases
- Comes with the ability to sort based on featured artists
- Supports manual and proxy scrobbling for third-party services
- Comes with an easy-to-understand API for better integration
Installation
The fastest way to install Maloja is by deploying it as a Docker container on your homelab. To do that, first install Docker and Docker Compose on your server.
Create a new folder on your homelab user’s home directory and navigate inside it:
mkdir ~/maloja && cd ~/maloja
Create a new docker-compose.yml file inside the Maloja directory:
nano ./docker-compose.yml
Paste the following block of code inside the Compose file:
services:
maloja:
image: "krateng/maloja:latest"
environment:
PUID: "1000"
PGID: "1001"
ports:
- "42010:42010"
volumes:
- "./config:/etc/maloja"
- "./data:/var/lib/maloja"
- "./logs:/var/log/maloja"
Create the necessary subdirectories, then start the Docker installation process:
mkdir ./{config,data,logs}
docker compose up -d
Once done, fetch the randomly generated password for your instance by running the following command:
docker compose logs | grep "Generated password:"

Lastly, confirm that the Maloja container is working properly by checking the active Docker processes on your system:
docker ps
Usage
To access your Maloja instance, open a web browser session and navigate to your homelab’s IP address followed by “:42010.”

Click the Gear icon on the page’s upper right corner.

Provide the randomly generated password that you got from the Docker container, then press Log-in.
Once done, the server will redirect you to the Overview page of its admin console. Here, you can update your current Maloja instance, enable “Admin Mode,” and export your scrobbling data.

The Server Setup category goes through some reminders on how to set up scrobbling for popular music platforms. It’s also where you can add custom rules that tweak Maloja’s default behavior.

The Settings category exposes some of the instance’s common variables. For example, you can set the location of the system directories, input the API keys from other scrobblers, and customize how your main page looks.

Finally, the API Keys category lists all the active keys for your Maloja instance. You can also generate a new API key here if you want to link an external tool to Maloja.
Linking Maloja to an Online Music Player
To start scrobbling on your web browser, first download web-based music scrobbler extension. Since I’m using Chromium, I’ve opted to install Web Scrobbler from the Chrome Web store.

Navigate to your Maloja Admin Console, then click API Keys.
Provide a name for your new API key under the Identifier text box, then click New Key.

Note: the developers of Maloja strongly suggest generating a new API key whenever you link a new service or tool to the instance.
Copy the API key to your clipboard, then open the Web Scrobbler extension panel.
Click the Gear icon to open the extension’s settings page.

Select the Accounts category, then scroll down to the Maloja section.
Paste the following line of code on the API URL textbox, replacing the “YOUR-HOMELAB-URL” with the IP address of your homelab:
http://YOUR-HOMELAB-URL:42010/apis/mlj_1/newscrobble
Paste your Maloja instance’s API key on the Token textbox, then click Save.

Confirm that the scrobbler is working properly by playing music from an online service, then checking the Maloja page.

Final Thoughts
Maloja is a lightweight and highly flexible music scrobbler for Docker-based home labs. In addition to scrobbling, it offers additional features that allow you to tweak and customize your experience.
Further, Maloja has tools that make it easy to migrate from an existing scrobbling system. As such, I fully recommend Maloja if you’re looking for a scrobbling server that’s easy to deploy and use. Alternatively, if you want to broadcast music from your server, check out our review of the AzuraCast internet radio server.
Be the first to comment! Get the discussion going.