Skip to content
Back to skills

Qbt Stats

ASecurity

Install, update, uninstall or troubleshoot qbt-stats, the qBittorrent statistics dashboard (http://localhost:8899). Use when the user asks to set up qBittorrent statistics, install or update qbt-stats, run it in Docker, or when the dashboard doesn't load, shows no data, or can't be opened from a phone or tablet.

  • 4 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added December 4, 2026
datapythongoshellsqldockergitapidatabase

Works with

  • claude code
  • terminal
  • cli
  • api

Security analysis

A92/100
  • mediumUses curl or wget to download content

Pro shows the line behind each finding and how to fix it

Scanned December 4, 2026

npx -y skills add Mrgabriel88/qbt-stats --skill qbt-stats --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Qbt Stats?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Qbt Stats
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/mrgabriel88-qbt-stats/badge)](https://www.skillsdirectory.com/skills/mrgabriel88-qbt-stats)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: qbt-stats
description: Install, update, uninstall or troubleshoot qbt-stats, the qBittorrent statistics dashboard (http://localhost:8899). Use when the user asks to set up qBittorrent statistics, install or update qbt-stats, run it in Docker, or when the dashboard doesn't load, shows no data, or can't be opened from a phone or tablet.
---

# qbt-stats

qbt-stats records qBittorrent's traffic into SQLite and serves a dashboard at http://localhost:8899.
The program files (`qbt_stats.py`, `dashboard.html`, `world.json`, `install.py`, `Dockerfile`,
`docker-compose.yml`, `README.md`) are in this plugin's root folder: two folders above this skill's
base directory. Call that folder ROOT below. Read `ROOT/README.md` when you need details.

## 1. Check the prerequisites first

1. **Python 3.9+**: `python3 --version` (Windows: `py --version`). If it's missing, tell the user how to get it for
   their system (Homebrew or python.org on macOS, the package manager on Linux, python.org on Windows) and stop.
2. **qBittorrent's Web UI must be on.** Test it:
   `curl -s http://localhost:8080/api/v2/app/version`
   - A version such as `v5.1.0` means it's on and lets this computer in without a login. Good.
   - `Forbidden` or a 403 means the Web UI is on but wants a login. Offer the two options:
     - Tick *Tools → Options → Web UI → Bypass authentication for clients on localhost* (easiest), then test again.
     - Or, with qBittorrent 5.2+ (`/api/v2/app/version` shows the version once it lets you in; otherwise ask),
       an **API key**: the user creates it under *Options → Web UI → API key* and enters it into the installer
       (see "Logins" below).
   - No answer: the Web UI is off, or uses another port. Ask the user to turn on *Tools → Options → Web UI* in
     qBittorrent and tell you the port if it isn't 8080.
   Ask the user to change qBittorrent's settings themselves; don't edit qBittorrent's config files.

## 2. Install or update (runs as a background service)

Run from any folder:

```
python3 "ROOT/install.py"
```

(Windows: `py "ROOT\install.py"`.) The same command updates an existing install and keeps the statistics.
Options, only when the user wants them: `--qbt-url URL` (other address or port), `--port N` (dashboard port),
`--no-lan` (no access from other devices at home), `--no-notify` (no weekly summary / low-disk notifications).

**Logins:** with an API key (`--api-key`) or a user name (`--qbt-user NAME`), the installer asks for the key
or password with a hidden prompt, which your shell can't answer. Never ask the user for an API key or password
in chat, and never put one in a command or file yourself. Give them the command to run in their own terminal:
`python3 "ROOT/install.py" --api-key` (or `--qbt-user NAME`). The installer checks an API key before saving it.
Settings are kept in `settings.json` in the data folder; updating keeps them, so a plain
`python3 "ROOT/install.py"` is right for updates. `--no-login` forgets a saved key or password.
Easier for the user: the dashboard's own settings (⚙︎ at the top right, on the computer it runs on) change the
login, address, port and notifications, and the user types any key or password there themselves.

When it says `Installed`, check `curl -s -o /dev/null -w "%{http_code}" http://localhost:8899/` gives 200,
then tell the user to open http://localhost:8899. The first ISP database download takes a minute; charts fill
in as data is recorded (every 30 seconds).

## Update to the newest version

When the user asks to update qbt-stats, or whether there's a new version:

1. **What runs now:** `curl -s http://localhost:8899/api/version` (another port if they installed with `--port`;
   the page shows the version next to its title too). Also note how it was installed: Homebrew if
   `brew list qbt-stats` succeeds, Docker if `docker ps --filter name=qbt-stats -q` prints an ID, otherwise
   `install.py` (directly, from a git clone, from this plugin or with the double-click installer).
2. **The newest version:** `curl -s https://api.github.com/repos/Mrgabriel88/qbt-stats/releases/latest`
   gives `tag_name` (e.g. `v0.3.0`) and `body`, the release notes. If the running version is the same, say
   it's up to date and stop.
3. **Update it the way it was installed:**
   - **Homebrew:** `brew update && brew upgrade qbt-stats`. Homebrew restarts the service.
   - **Docker:** in the folder with the user's `docker-compose.yml`: `docker compose pull && docker compose up -d`
     (or `docker compose up -d --build` if it builds from a clone: run `git pull` there first).
   - **A git clone:** `git pull` in it, then `python3 install.py` there.
   - **Otherwise:** read `__version__` in `ROOT/qbt_stats.py`. If it's the newest version, run
     `python3 "ROOT/install.py"` (step 2 above). If it's older, this plugin's files are out of date: tell the user
     which version you'll download, from where, and ask before downloading. Then put the release's
     `qbt-stats-<version>.tar.gz` (Windows: the `.zip`) from
     `https://github.com/Mrgabriel88/qbt-stats/releases/download/v<version>/` into a new empty temporary folder,
     unpack it there, and run `python3 "<that folder>/qbt-stats-<version>/install.py"`. Only ever download from
     that address. Mention that `claude plugin update qbt-stats@qbt-stats` (after
     `claude plugin marketplace update qbt-stats`) also brings these instructions up to date, effective after a
     restart of Claude Code.
   Updating keeps the statistics and the settings; don't pass options the user didn't ask to change.
4. **Check:** `/api/version` shows the new version. Summarize what's new from the release notes in a few lines.

## Installed with Homebrew or the double-click installer?

- Homebrew (`brew list qbt-stats` succeeds): update with `brew upgrade qbt-stats`; change settings with
  `qbt-stats-config` (same options as `install.py`, e.g. `--port`), then `brew services restart qbt-stats`.
  The login options (`--api-key`, `--qbt-user`) prompt hidden, so the user runs those in their own terminal.
  Don't also install it with `install.py`: both would use port 8899.
- The double-click installers (`Install qbt-stats.command` / `.bat` from a release zip) run
  `install.py --guided`, so everything in step 2 applies to them.

## 3. Docker instead

Only when the user asks for Docker. The plugin folder is a cache that updates replace, so first copy the project
to a folder the user chooses (or `git clone https://github.com/Mrgabriel88/qbt-stats.git` there). Then:
1. Edit `docker-compose.yml` with them: `QBT_URL` (qBittorrent on the same machine:
   `http://host.docker.internal:8080`; in the same Compose file: its service name), `TZ`, and optionally
   the download folder mount for disk statistics.
2. qBittorrent sees the container as another computer, so the user either adds the Docker network to
   *Bypass authentication for clients in whitelisted IP subnets* (e.g. `172.16.0.0/12`) or sets
   `QBT_USER`/`QBT_PASS` in the compose file themselves.
3. `docker compose up -d --build`, then check http://localhost:8899.
In Docker the dashboard is read-only unless `QBT_STATS_ACT_FROM` lists who may pause, limit and remove torrents.

## 4. Uninstall

`python3 "ROOT/install.py" --uninstall` keeps the statistics. Add `--purge` to delete them too, but only after the
user confirms that, since it can't be undone.

## 5. Troubleshooting

- **Logs:** macOS `~/Library/Logs/qbt-stats.log`; Linux `journalctl --user -u qbt-stats -n 50`;
  Windows `%LOCALAPPDATA%\qbt-stats\qbt-stats.log`; Docker `docker logs qbt-stats`.
- **Service state:** macOS `launchctl print gui/$(id -u)/local.qbt-stats`; Linux
  `systemctl --user status qbt-stats`; Windows `schtasks /Query /TN qbt-stats`, or, when Windows refused that task, the `qbt-stats` value under
  `HKCU\Software\Microsoft\Windows\CurrentVersion\Run`.
- **"qBittorrent rejected the API key"** or **"asks for a login"** in the page: the key was renewed or
  mistyped, or the localhost bypass was turned off. Have the user run the installer with `--api-key` again.
- **Port 8899 taken** (the installer says so; on QNAP NAS boxes RTRR uses it): install with `--port 8900`.
- **Version:** shown next to the page title, and at `http://localhost:8899/api/version`.
- **"Can't reach qBittorrent"** in the page: qBittorrent isn't running, or the Web UI check in step 1 fails.
- **Phone or tablet can't open it:** use `http://<computer-name>.local:8899` or the computer's IP, not
  `localhost`. Check the install didn't use `--no-lan`, and that the firewall allows incoming connections
  for Python. Other devices only get a read-only page; that's intended.
- **403 Forbidden:** the address isn't localhost, a private IP or `<computer-name>.local` (other host names
  are refused on purpose).
- Never run pause, remove or limit actions on the user's torrents to test anything.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in data →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.