Common Command-Line Options
This page documents common command-line options and concepts shared across copyparty tools.Volume Permissions
Permissions control what users can do within a volume. Specified in volume definitions after the mount path.Permission Flags
Read - List folder contents and download files.
Write - Upload files. Requires
r to see the uploads.Move - Move files and folders. Requires
w at destination.Delete - Permanently delete files and folders.
Get - Download files without seeing folder contents.
Upget - Like
g, but can see filekeys of own uploads.HTML - Like
g, but folders return their index.html.Dots - User can request to show dotfiles in listings.
Admin - View uploader IPs, trigger config reload.
All - Same as
rwmda. (read/write/move/delete/admin/dots).Permission Examples
Volume Flags
Volume flags (volflags) modify volume behavior. Specified after permissions with:c,flag1,flag2.
Upload Flags
Reject duplicate files during upload.Example:
-v /tmp/inc:/inc:w:c,nodupeEnable symlink-based upload deduplication.
Use hardlinks for deduplication (falls back to symlinks).
How to timestamp uploaded files:
c (client), u (upload-time), fc, fu.Filename pattern for nameless uploads.Default:
put-{now.6f}-{cip}.binFilesystem Flags
Unix file permissions (octal) for new files.Example:
chmod_f=644Unix directory permissions (octal) for new directories.Example:
chmod_d=755Database durability profile:
acid, swal, wal, yolo.Example: -v ~/music:music:r:c,dbd=swalPrevent creating subdirectories.
Display Flags
Enable the
?dots URL parameter to show hidden files.Display subdirectory contents in upload page (slow).
Thumbnail conversion quality/size.
Access Control Flags
Force authentication for all folders (required by davfs2).
Who can create shares:
no, a (admin), auth (authenticated).Who can undo uploads:
0 (none), 1 (same IP+account), 2 (same IP), 3 (same account).Event Hooks
Event hooks execute commands before/after various events. Can be global options or volume flags.Hook Types
Execute command before a file upload starts.Arguments: File path or JSON info
Execute command after a file upload finishes.Arguments: File path or JSON info
Execute command after all uploads finish and volume is idle.Arguments: List of uploaded files (JSON on stdin)Note: Batches multiple uploads, runs once after idle period.
Execute command before a file copy.
Execute command after a file copy.
Execute command before a file rename/move.
Execute command after a file rename/move.
Execute command before a file delete.
Execute command after a file delete.
Execute command when a message is posted.Arguments: Message text or JSON
Execute command when someone gets banned.Return: 0 (true) to cancel the ban
Hook Flags
Prefix hooks with comma-separated flags: Execution:f- Fork process, don’t wait for completionc- Check return code, block action if non-zerow N- Wait N seconds after command startstN- Set N second timeoutiN- (xiu only) Volume idle time in seconds (default 5)I- Import and run as module (140x faster)
j- Provide JSON info as 1st argument instead of filepaths- Provide data on stdin instead of argumentc0- Show all output (default)c1- Show only stderrc2- Show only stdoutc3- Mute all output
ar- Only run if user has read permissionarw- Only run if user has read+writearwmd- Only run if user has all permissions
kt- Kill process tree on timeout (default)km- Kill main process onlykn- Let it run until copyparty terminates
Hook Examples
Authentication Options
Password Hashing
Password hashing algorithm:
none- Plaintext (default, not recommended for production)argon2- Argon2id (recommended)scrypt- Scryptsha2- SHA2-512
--ah-alg argon2Generate hashed password for the given plaintext.Example:
--ah-gen hunter2IdP / SSO Integration
HTTP header containing username from IdP (repeatable).Warning: Ensure clients cannot set this header!Example:
--idp-h-usr Remote-UserHTTP header containing groups from IdP.Example:
--idp-h-grp Remote-GroupsSecret header that must be present to trust IdP headers.Example:
--idp-h-key X-Secret-KeyAuthentication precedence order.Options:
pw (password), idp (identity provider), ipu (IP-based)Examples:pw,idp,ipu- Try password firstipu,idp,pw- IP auth winsidp- Only IdP authentication
IP-Based Authentication
Auto-authenticate IPs as specific user (repeatable).Format:
CIDR=USERNAMEExample: --ipu 192.168.1.0/24=alice --ipu 10.0.0.5=bobRestrict user to specific IPs (repeatable).Format:
CIDR1,CIDR2=USERNAMEExample: --ipr 192.168.1.0/24,10.0.0.0/8=aliceDatabase Durability Profiles
Controls how aggressively the database is synced to disk.Extremely safe but slow - Never lose data, even in power loss.Best for: Critical data, single points of failure
2.4x faster, 99.9% as safe - May lose metadata for ~200 recent uploads in power loss.Best for: General use, good balance of speed and safety
21x faster on HDD, 90% as safe - Higher risk of metadata loss.Best for: High-volume uploads, HDD arrays
Fastest, removes upload pauses - Risk of losing entire database.Best for: Temporary data, SSD caching, reproducible uploads
Setting Durability
File Permissions (chmod)
Unix file permission settings for new files and directories.Permission Bits
User, Group, Other digits:0=---(no access)1=--x(execute)2=-w-(write)3=-wx(write + execute)4=r--(read)5=r-x(read + execute)6=rw-(read + write)7=rwx(read + write + execute)
1= Sticky bit2= Setgid4= Setuid
Common Examples
Environment Variables
Default config file path (same as
-c).Disable TLS/SSL support entirely.
Disable timestamp touching in SFX builds.
Config File Format
Config files use INI-style format with[global] and [volume] sections.
Example Config
Config Sections
[global]- Server-wide settings (maps to--option)[/path]or[path:alias]- Volume definitions- First line specifies permissions
- Following lines are volume flags
Loading Configs
Exit Codes
0- Success1- Error (authentication failed, port in use, etc.)130- Interrupted (Ctrl+C)