Quick Start Guide
This guide will get you up and running with 7-Zip quickly. You’ll learn the most common operations: creating archives, extracting files, listing contents, and testing archive integrity.On Linux/macOS, use
7zz as the command. On Windows, use 7z (or 7z.exe with full path). The examples below use 7z for simplicity, but both work identically.Basic Command Structure
7-Zip commands follow this pattern:- command - Single letter command (a, x, e, l, t, etc.)
- switches - Optional parameters starting with
- - archive_name - Name of the archive file
- file_names - Files or directories to process
Creating Your First Archive
1
Create a simple archive
Compress a single file or directory into a 7z archive:The
a command means add to archive. If the archive doesn’t exist, 7-Zip creates it.2
Set compression level
Control the compression ratio vs. speed tradeoff:Compression levels:
-mx0- Store only (no compression)-mx1- Fastest compression-mx3- Fast compression-mx5- Normal (default)-mx7- Maximum-mx9- Ultra (slowest, best compression)
3
Create a password-protected archive
Add encryption to protect sensitive data:7-Zip will prompt you to enter a password. To specify the password inline:
4
Create archives in other formats
Use the Supported archive types for creation:
-t switch to specify the archive format:7z- 7-Zip native format (default, best compression)zip- ZIP archivegzip- GZIP compressedbzip2- BZIP2 compressedtar- TAR archive (no compression)wim- Windows Imaging Formatxz- XZ compressed
Extracting Archives
1
Extract with full paths
Use the
x command to extract files with their directory structure:Note: There is no space between
-o and the path. The correct syntax is -o/path/ not -o /path/.2
Extract without paths
Use The
e to extract all files to a single directory (no subdirectories):e command extracts all files to the same folder, ignoring the original directory structure.3
Extract password-protected archives
Provide the password when extracting encrypted archives:
4
Extract specific files
Extract only certain files from an archive:
Listing Archive Contents
Before extracting, you can view what’s inside an archive:1
List files in archive
Use the Output shows:
l (list) command:- Date and time
- File attributes
- File size
- Compressed size
- File name
2
Show technical information
Get detailed technical information about the archive:This displays:
- Compression method
- CRC checksums
- Encryption details
- Block information
- Archive properties
Testing Archives
Verify archive integrity without extracting:t command checks:
- CRC checksums
- Archive structure
- Compression integrity
- File data validity
Common Use Cases
Backup a Directory
Split Large Archives into Volumes
large_archive.7z.001large_archive.7z.002large_archive.7z.003- etc.
Update Existing Archive
Delete Files from Archive
Hash Calculation
Benchmark System Performance
Test your CPU’s compression and decompression speed:Useful Switches Reference
Here are the most commonly used switches:Command Quick Reference
Best Practices
Next Steps
Command Reference
Explore all available commands and switches in detail
Advanced Usage
Learn advanced techniques like SFX archives, filtering, and automation
Format Specifications
Understand the 7z format and other supported archive types
Compression Methods
Deep dive into LZMA, LZMA2, PPMd, and other compression algorithms