Online tool

aria2.conf Configuration Generator

Pick a preset, adjust what you need, and download a ready-to-use aria2.conf. The generator checks your choices as you go and catches the mistakes that stop aria2 from starting.

Last updated: Tested with aria2 1.37.0

Files

Use ${HOME} for your home folder. "~" does not work inside aria2.conf.

Speed
5
16
16

aria2 never splits off a piece smaller than this, so small files use fewer connections.

Remote control
BitTorrent
Advanced

Only if HTTPS downloads fail with certificate errors. The option is ca-certificate; "ca-bundle" does not exist.

Connections per file16
At most, in total80
Memory cache32 MiB
Remote controlthis computer
aria2.conf 51 lines
# aria2.conf, made with the generator at https://aria2.org/config-generator/# Lines starting with # are comments. key=value here is the same as aria2c --key=value. # ── Files ──# Where finished files are saved. ${HOME} is your home folder; ~ does not work here.dir=${HOME}/Downloads# Resume partly downloaded files instead of starting over.continue=true# How disk space is reserved before writing: none, prealloc, trunc or falloc.file-allocation=falloc # ── Session ──# Remember unfinished downloads across restarts. Create this file once: aria2 will not start if it is missing.input-file=${HOME}/.aria2/aria2.sessionsave-session=${HOME}/.aria2/aria2.sessionsave-session-interval=60 # ── Speed ──# How many downloads run at the same time.max-concurrent-downloads=5# Connections to one server for each download (1 to 16).max-connection-per-server=16# Pieces each file is split into and downloaded in parallel.split=16# Smallest piece aria2 will split off.min-split-size=4M# Overall speed limits in bytes per second. 0 means unlimited; K and M work (5M = 5 MiB/s).max-overall-download-limit=0max-overall-upload-limit=0# Memory used to batch disk writes. 0 turns the cache off.disk-cache=32M # ── Remote control (JSON-RPC) ──enable-rpc=true# Password for the WebUI and other RPC clients. Keep it private.rpc-secret=CHANGE_ME# Lets browser-based WebUIs talk to aria2.rpc-allow-origin-all=true# Accept connections from this computer only.rpc-listen-all=falserpc-listen-port=6800 # ── BitTorrent ──# DHT, peer exchange and local peer discovery find peers without a tracker. Off for private trackers.enable-dht=trueenable-peer-exchange=truebt-enable-lpd=true# Seed until the share ratio reaches this value.seed-ratio=1.0# Extra public trackers (ngosang/trackerslist, best list). Fresh list: https://aria2.org/trackers/bt-tracker=udp://tracker.opentrackr.org:1337/announce,udp://open.stealth.si:80/announce,udp://open.demonii.com:1337/announce,udp://exodus.desync.com:6969/announce,http://open.tracker.cl:1337/announce,udp://tracker.qu.ax:6969/announce,udp://tracker-udp.gbitt.info:80/announce,udp://tracker.bittor.pw:1337/announce,udp://tracker.corpscorp.online:80/announce,udp://tracker.dler.org:6969/announce,http://tracker.dler.com:6969/announce,udp://tracker2.dler.org:80/announce,udp://tracker.ducks.party:1984/announce,udp://explodie.org:6969/announce,udp://tracker.nyaa.vc:6969/announce,http://tracker.renfei.net:8080/announce,udp://tracker.gmi.gd:6969/announce,udp://tracker.t-rb.org:6969/announce,udp://tracker.ixuexi.click:6969/announce,udp://tracker.edkj.club:6969/announce

Config check

  • Set an RPC secret of at least 12 characters. Without one, anything that reaches the port can control aria2.
  • Create the session file once before you start aria2, or it stops with "Failed to open the file … File not found".

Every preset is checked against aria2 1.37.0.

Where to save aria2.conf

aria2 reads its config file from your home folder automatically. Create the folder if it does not exist. To keep the file anywhere else, start aria2 with --conf-path.

SystemDefault locationCreate the folder and session file
Linux~/.aria2/aria2.confmkdir -p ~/.aria2 && touch ~/.aria2/aria2.session
macOS~/.aria2/aria2.confmkdir -p ~/.aria2 && touch ~/.aria2/aria2.session
Windows%USERPROFILE%\.aria2\aria2.confNew-Item -ItemType File -Force "$env:USERPROFILE\.aria2\aria2.session"

If ~/.aria2/aria2.conf does not exist, aria2 looks for $XDG_CONFIG_HOME/aria2/aria2.conf (usually ~/.config/aria2/aria2.conf). In a terminal "~" works as usual; only inside aria2.conf must you write ${HOME}.

Start aria2 with your config

aria2 picks up the file by itself, so plain aria2c is enough. The Linux commands were run with aria2 1.37.0; the Windows command was checked but not run.

Linux and macOS
# Once: create the folder and the empty session filemkdir -p ~/.aria2 && touch ~/.aria2/aria2.session# Start aria2 with ~/.aria2/aria2.confaria2c# Or use a config file somewhere elsearia2c --conf-path=/path/to/aria2.conf# A one-off download that skips the session queuearia2c --input-file= https://example.com/file.iso
Windows (PowerShell)
# Once: create the folder and the empty session fileNew-Item -ItemType File -Force "$env:USERPROFILE\.aria2\aria2.session"# Start aria2 with %USERPROFILE%\.aria2\aria2.confaria2c

Check that remote control works

With RPC turned on, aria2 keeps running and waits for commands. Ask it for its version, using your own secret:

curl -s http://localhost:6800/jsonrpc -d '{"jsonrpc":"2.0","id":1,"method":"aria2.getVersion","params":["token:YOUR_SECRET"]}'{"id":1,"jsonrpc":"2.0","result":{"enabledFeatures":["Async DNS","BitTorrent","Firefox3 Cookie","GZip","HTTPS","Message Digest","Metalink","XML-RPC","SFTP"],"version":"1.37.0"}}

A wrong secret returns {"code":1,"message":"Unauthorized"}. If it works, open the online WebUI and connect with the same secret.

Which preset should I pick?

The four presets side by side. Every value comes from the same code that writes your file.

01

Fast desktop

For most people. 16 connections and 16 pieces per file use a fast line fully, falloc reserves space instantly, and RPC on this computer only lets you add downloads from the WebUI or a browser extension.

02

NAS / home server

For a machine that runs all the time. It starts in the background, saves into /downloads and accepts RPC from other devices on your network. Use it only behind your router, never with port 6800 open to the internet.

03

Low-power device

For a Raspberry Pi or an old laptop. Two downloads with four connections each, a small memory cache, no pre-allocation (kind to SD cards) and no seeding after the download.

04

Private trackers

For private trackers. DHT, peer exchange and local discovery are off and no public trackers are added, so peers come only from your tracker. It keeps seeding with no ratio limit. Check your site's allowed-client list first: not every private tracker accepts aria2.

SettingFast desktopNAS / home serverLow-power devicePrivate trackers
dir${HOME}/Downloads/downloads${HOME}/Downloads${HOME}/Downloads
file-allocationfallocfallocnonefalloc
max-concurrent-downloads5525
max-connection-per-server1616416
split1616416
min-split-size4M8M20M4M
disk-cache32M64M8M32M
enable-rpcononoffon
rpc-listen-alloffon—off
daemonoffonoffoff
enable-dhtonononoff
bt-trackeronononoff
seed-ratio / seed-timeratio 1.0ratio 1.0stop at 100 %forever

What each option does

Every key maps 1:1 to an aria2c flag: max-connection-per-server=16 in the file is --max-connection-per-server=16 on the command line.

Keyaria2 defaultWhat it does
dircurrent folderFolder for finished files.
continuefalseResume a partly downloaded file instead of starting over.
file-allocationpreallocHow disk space is reserved: none, prealloc, trunc or falloc.
input-file / save-session—Read the queue at start and write unfinished downloads back, so they survive a restart.
save-session-interval0Save the session every N seconds; 0 saves only when aria2 exits.
max-concurrent-downloads5Downloads that run at the same time.
max-connection-per-server1Connections to one server per download, 1 to 16. The biggest speed lever.
split5Pieces each file is split into. A file never uses more connections than this.
min-split-size20MSmallest piece. Files smaller than twice this size are not split.
max-overall-download-limit0Total download speed limit; 0 is unlimited.
max-overall-upload-limit0Total upload speed limit; 0 is unlimited.
disk-cache16MMemory used to batch disk writes.
enable-rpcfalseStarts the JSON-RPC server that WebUIs and extensions talk to.
rpc-secret—Password every RPC call must send as token:SECRET.
rpc-allow-origin-allfalseAllows browser-based WebUIs to call aria2.
rpc-listen-allfalseListen on all network interfaces instead of this computer only.
rpc-listen-port6800Port of the RPC server (1024 to 65535).
daemonfalseRun in the background; the working folder becomes /.
enable-dht / enable-peer-exchangetrueFind peers without a tracker. aria2 turns both off for torrents marked private.
bt-enable-lpdfalseFind peers on your local network.
seed-ratio1.0Stop seeding at this share ratio; 0.0 seeds regardless of ratio.
seed-time—Stop seeding after N minutes; 0 stops right after the download.
bt-tracker—Extra trackers, separated by commas.
ca-certificatedepends on the buildCA certificates used to verify HTTPS servers.

All 198 options are in the options reference.

Six mistakes that break aria2.conf

We made each of these on purpose with aria2 1.37.0. This is what aria2 does, word for word.

  1. 01 "~" in a path

    dir=~/Downloads

    aria2 saves into a folder literally named "~" inside the current folder.

    dir=${HOME}/Downloads
  2. 02 A missing session file

    input-file=${HOME}/.aria2/aria2.session

    Exception: [download_helper.cc:562] errorCode=1 Failed to open the file /root/.aria2/aria2.session, cause: File not found or it is a directory

    mkdir -p ~/.aria2 && touch ~/.aria2/aria2.session
  3. 03 A comment after a value

    split=16 # sixteen

    errorCode=1 Bad number 16 # sixteen

    # sixteen
    split=16
  4. 04 Quotes around a path

    dir="/mnt/my downloads"

    aria2 keeps the quotes: it creates a folder whose name starts with ".

    dir=/mnt/my downloads
  5. 05 A value out of range

    max-connection-per-server=32

    errorCode=1 max-connection-per-server must be between 1 and 16.

    max-connection-per-server=16
  6. 06 An option that does not exist

    ca-bundle=/etc/ssl/cert.pem

    [WARN] Unknown option: ca-bundle=/etc/ssl/cert.pem

    ca-certificate=/etc/ssl/cert.pem

Troubleshooting

aria2c prints "No files to download."

Your config has input-file set. When it is, aria2 reads downloads from the session file and ignores URLs on the command line. That is right for an RPC server, but for a one-off download clear it for that run:

aria2c --input-file= https://example.com/file.iso

aria2 stops with "Parse error in aria2.conf"

A line has a value aria2 cannot read. The next lines name the option, for example Bad number 16 # sixteen or must be between 1 and 16. Comments must be on their own line, and numbers must be in range. aria2 refuses to start (exit code 28) until the line is fixed.

aria2 warns "Unknown option"

The key is misspelled or does not exist in your aria2 version. aria2 ignores the line and starts anyway, so the setting silently has no effect. Look the key up in the options reference.

aria2 logs "IPv6 RPC: failed to bind TCP port 6800"

Harmless when your system has IPv6 turned off: aria2 tries IPv6 and IPv4, and the RPC server still works over IPv4. We see the same line with no config file at all. Only if a second line says IPv4 RPC: failed to bind is the port really taken; then stop the other program or change rpc-listen-port.

The WebUI cannot connect

Check that the file has enable-rpc=true and rpc-allow-origin-all=true, and that you enter the same rpc-secret in the WebUI. Restart aria2 after editing the file. For another device on your network you also need rpc-listen-all=true; see the WebUI troubleshooting.

Downloads start from zero after a reboot

Turn on Remember unfinished downloads: it writes input-file, save-session and save-session-interval. Keep continue=true and make sure the session file and the download folder are on a disk that survives a reboot.

Which disk allocation should I choose?

falloc on ext4, btrfs, xfs and NTFS: it reserves space almost instantly. none on FAT32, exFAT and SD cards. Avoid prealloc for large files on slow disks, because it writes the whole file before downloading. See the speed guide.

FAQ

Is the generator private?

Yes. The file is built in your browser. Nothing you type, including the RPC secret, is sent to aria2.org.

Can I use the file on Windows?

Yes. Save it as %USERPROFILE%\.aria2\aria2.conf. ${HOME} paths work there too: aria2 uses your user folder when the HOME variable is not set. Leave Run in the background off on Windows.

Does a higher number of connections always mean faster downloads?

Only when one connection is limited by the server rather than by your line. aria2 caps connections per server at 16. The speed guide shows when more connections help and when they do not.

How do I keep the tracker list fresh?

The generator adds today's best list. Trackers change over time, so refresh bt-tracker from the tracker list, which also has a script that updates the line automatically.

Related resources