Appearance
Magnet Utilities
Tools and knowledge for working with magnet links and info hashes directly.
Anatomy of a Magnet Link
A magnet URI looks like this:
magnet:?xt=urn:btih:08ada5a7a6183aae1e09d831df6748d566095a10&dn=Example+File&tr=udp%3A%2F%2Ftracker.example.com%3A1337| Parameter | Meaning |
|---|---|
xt=urn:btih: | Exact topic — the info hash (SHA-1 or SHA-256) |
dn= | Display name — suggested filename (optional, not trusted) |
tr= | Tracker URL — one per tr= parameter (optional, DHT works without) |
xl= | Exact length — total size in bytes (optional) |
as= | Acceptable source — fallback HTTP URL for the file (optional) |
The only required part is xt=urn:btih: — everything else is optional. A bare magnet link with just the info hash will still work if the torrent is in the DHT network.
Info Hash Formats
Older torrents use SHA-1 info hashes (40 hex characters):
08ada5a7a6183aae1e09d831df6748d566095a10Newer torrents (BitTorrent v2) use SHA-256 (64 hex characters):
631a31dd0a46257d5078c0dee4e4e847cc55f9e3c1e8b6890d3b37c2e8cf0d78Both appear in magnet links under xt=urn:btih: (v1) or xt=urn:btmh: (v2).
Command-Line Tools
webtorrent-cli
Fetches torrent metadata and can stream video directly:
bash
npm install -g webtorrent-cli
# Get info about a magnet link
webtorrent magnet:?xt=urn:btih:... --no-connection
# Stream a torrent to VLC
webtorrent magnet:?xt=urn:btih:... --vlcaria2
A fast, lightweight download utility with BitTorrent support:
bash
# Download a magnet link
aria2c "magnet:?xt=urn:btih:..."transmission-cli
Transmission's CLI client handles magnet links directly:
bash
transmission-cli "magnet:?xt=urn:btih:..."Searching by Info Hash
If you have an info hash and want to find active torrents for it, you can:
- Paste the hash directly into Magnetz search
- Construct a magnet link:
magnet:?xt=urn:btih:YOURHASHand open it — DHT will find peers - Search on public tracker sites using the hash
Adding Extra Trackers
Adding more tracker URLs to a magnet link can improve peer discovery, especially for older or less-popular torrents:
magnet:?xt=urn:btih:HASH&tr=udp://tracker.opentrackr.org:1337/announce&tr=udp://open.tracker.cl:1337/announceA maintained list of active public trackers: github.com/ngosang/trackerslist
Most modern torrent clients also let you add trackers to an existing torrent after it's been added — right-click → Edit Trackers (qBittorrent) or Properties → Trackers (Deluge).