Skip to content
Switch branches/tags

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time


Build Status

NOTE : If you're a user, Plex includes its own internal scrobbling capabilities. In order to enable your Plex.Tv account for Last.FM integration browse to and link your account from the Other Services . Announcment was made public via .

plex-lastfm-scrobbler provides a set of scripts that allow you to scrobble played audio items to Last.FM from the Plex Media Server application. plex-lastfm-scrobbler was built to run across platforms, though only tested on Linux.

A few points

  • plex-lastfm-scrobbler is an out of process tool. Meaning it is not a Plex Media Server plug-in. This tool runs separately of your Plex Media Server.
  • Must be run on the Plex Media Server
  • Parses Plex Media Server logs for the 'got played' string in the log file.
  • Does not differentiate between clients. Meaning all media played, will be scrobbled while the script is running.
  • Your plex-media-server logs must be set at DEBUG level (not VERBOSE)


Linux, OSX

It is recommended (but not required) that you install this into a virtualenvironment. This can be done as such.

virtualenv ~/.virtualenvs/plex-lastfm-scrobbler
source ~/.virtualenvs/plex-lastfm-scrobbler/bin/activate

Installing via pip or easy_install is supported. For example :pip install plex-scrobble or easy_install plex-scrobble.

If you wish to run development builds, fetch and install the source from the github repo.

git clone
cd plex-lastfm-scrobbler
python install
pip install -r dev_requirements.txt # for mock/testing packages.

Alternatively, you can fetch the latest zip from github

cd plex-lastfm-scrobbler-master
python install

You're done.


Run the wizard to generate config file

plex-scrobble --wizard

The plex-lastfm-scrobbler configuration file (.plex-scrobble.toml) is installed to ~/ . The following configuration values are available.

If you're running Plex Media Server on a Linux based operating system, things should work out of the box.

# REQUIRED: You'll need to create a API application first. Do so here:
api_key = "YOUR_API_KEY"
api_secret = "YOUR_API_SECRET"
user_name = "LAST_FM_USERNAME"
password = "LAST_FM_PASSWORD"

# mediaserver_log_location references the log file location of the plex media server
# the default under /var/lib/... is the default install of plex media server on
# a Linux system. You may wish to change this value to reference your OS install.
mediaserver_log_location = "/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Logs/Plex Media Server.log"

# REQUIRED: Where do you wish to write the plex-scrobble log file.
log_file = "/tmp/plex-scrobble.log"

# REQUIRED: mediaserver_url is the location of the http service exposed by Plex Media Server
# the default values should be 'ok', assuming you're running the plex scrobble
# script from the same server as your plex media server
mediaserver_url = "http://localhost:32400"

# REQUIRED: a python data struture that stores failed scrobbles. plex-scrobble
# will retry on a 60 minute interval, maximum of 10 attempts if is
# experiencing issues.
cache_location = "/tmp/plex_scrobble.cache"

# OPTIONAL: plex_token defines the plex token used to get metadata
# Note: This is required if you use localhost or and Plex Media Server >= 1.1.0
# You will know if you see a line like this your log_file:
# [plex_scrobble.plex_monitor fetch_metadata] [ERROR] urllib2 error reading from http://localhost:32400/library/metadata/48080 'HTTP Error 401: Unauthorized'
# Here is how you can obtain your token
plex_token = "YOUR_PLEX_TOKEN"


If you installed plex-lastfm-scrobble to a virtual environment, enable the virtual env.

source ~/.virtualenvs/plex-lastfm-scrobbler/bin/activate

run the application

nohup plex-scrobble &

Troubleshooting & Known Issues

Or browse the github issues list to review old bugs or log a new problem. See