-o (set Output directory) switch

Specifies a destination directory where files are to be extracted.

This switch can be used only with extraction commands.


This is the destination directory path. It's not required to end with a slash.


7z x archive.zip -o/Doc

extracts all files from the archive.zip archive to the /Doc directory.

7z x *.zip -o*

extracts all *.zip archives to subfolders with names of these archives.

Commands that can be used with this switch

e (Extract), x (Extract with full paths)