Command Line Switches

Syntax

<switch>::= -<switch_characters>[<option>]

On the command line, a switch consists of a switch specifier, either a dash (-) or a forward slash (/), followed by the name of the switch. Switch names cannot be abbreviated.

Some switches take an argument after the switch name. No spaces or tabs are allowed within a switch specification. Switch names are not case sensitive, but arguments can be case sensitive.

Switch can be used in any place in command line.

See also for more details about using the command line.

Switch quick reference

Switch Description
-ad Show dialog box in GUI version (7zg)
Set output log level
-bd Disable progress indicator
Set output stream for output/error/progress
-bt Show execution time statistics
-snt[-] Replace trail dots and spaces in file names for Extract operation
-snc Extract file as alternate stream, if there is ':' character in name
-snr Replace ':' character to '_' character in paths of alternate streams
-snh Store hard links as links (WIM and TAR formats only)
-snl Store symbolic links as links (WIM and TAR formats only)
-spd Disable wildcard matching for file names
-spe Eliminate duplication of root folder for extract archive command
-sse Stop archive creating, if 7-Zip can't open some input file
-stm{HexMask} Set CPU thread affinity mask (hexadecimal number).
Exclude archive type