NSZ - Homebrew compatible NSP/XCI compressor/decompressor
Python
2,409
679 commits
updated Aug 23, 2026
A compression/decompression script (with optional GUI) that compresses or decompresses Nintendo Switch dumps losslessly thanks to the zstd compression algorithm. The compressed file can be installed with supported NSW Homebrew Title Installers.
You need to have a hactool compatible keys file in a suitable directory to use this tool.
You must legally obtain your keys!
The keys file must be named either prod.keys or keys.txt. It must be located either in the directory in which you are running this software or:
| OS | Location |
|---|---|
| linux | $HOME/.switch/, $XDG_CONFIG_HOME/nsz/, $HOME/.config/nsz/ |
| macOS | $HOME/.switch/ |
| windows | %USERPROFILE%/.switch/ |
You can also provide a custom keys path at runtime using the --keys /path/to/prod.keys parameter. This may be a direct path to the file or a directory containing prod.keys or keys.txt.
There are several ways to run this tool. Choose from one of the methods below.
You can find the binaries in the release page.
On most Linux systems you will need to right-click the file, open the properties, and choose to "Allow executing file as program".
Mac systems are much more strict about which software is allowed to be ran on the system. You must make the file executable from the terminal with chmod +x nsz-cli-macos or chmod +x nsz-gui-macos. After trying to run the program you will be stopped by security. Go to System Settings > Privacy & Security then scroll down and choose to allow running the program.
Requires Python 3.6+.
This tool can be run from the source code.
pip3 install -r requirements.txt to install the requirements for the CLI only, or pip3 install -r requirements-gui.txt to install the requirements for the CLI and GUI.python3 nsz.py to start the program.Requires Python 3.6+.
Use the following command to install the console-only version:
pip3 install --upgrade nsz
Use the following command to install the GUI version:
pip3 install --upgrade nsz[gui]
NSZ is available as a Docker container with multi-architecture support for easy deployment and usage without needing to install Python.
The container provides:
For complete Docker setup, build instructions, and usage examples see container/README.md.
Quick example:
# Build for local testing
make -C container build-single-arch
# Use with your Nintendo Switch keys
docker run --rm -v "$(pwd)":/data -v "$HOME/.switch/prod.keys":/root/.switch/prod.keys nsz-tool:latest application.nsp
Comprehensive lists of command line parameters and usage examples are in the dedicated usage documentation.
To view all possible flags and their descriptions check the Usage section.
Automated bulk file operation examples are in scripts.
Explanations of the file formats introduced by NSZ are found in the formats documentation.
If you are interested in reporting/fixing issues and contributing directly to the code base, please see CONTRIBUTING.md for more information on how to get started.
The Swiss mirror will be the new home in case GitHub ever takes down this repository. Please bookmark it.
NSZ pip package: https://pypi.org/project/nsz/
Forum thread: https://gbatemp.net/threads/nsz-homebrew-compatible-nsp-xci-compressor-decompressor.550556/
Licensed under the MIT license.
Overall
Maintained
Code review
PyPI
Latest release
Releases this year
766 followers · starred Jul 2025
11,118 followers · starred Nov 2025
155 followers · starred Mar 2026
66 followers · starred Apr 2025
NSZ - Homebrew compatible NSP/XCI compressor/decompressor
Python
2,409
679 commits
updated Aug 23, 2026
A compression/decompression script (with optional GUI) that compresses or decompresses Nintendo Switch dumps losslessly thanks to the zstd compression algorithm. The compressed file can be installed with supported NSW Homebrew Title Installers.
You need to have a hactool compatible keys file in a suitable directory to use this tool.
You must legally obtain your keys!
The keys file must be named either prod.keys or keys.txt. It must be located either in the directory in which you are running this software or:
| OS | Location |
|---|---|
| linux | $HOME/.switch/, $XDG_CONFIG_HOME/nsz/, $HOME/.config/nsz/ |
| macOS | $HOME/.switch/ |
| windows | %USERPROFILE%/.switch/ |
You can also provide a custom keys path at runtime using the --keys /path/to/prod.keys parameter. This may be a direct path to the file or a directory containing prod.keys or keys.txt.
There are several ways to run this tool. Choose from one of the methods below.
You can find the binaries in the release page.
On most Linux systems you will need to right-click the file, open the properties, and choose to "Allow executing file as program".
Mac systems are much more strict about which software is allowed to be ran on the system. You must make the file executable from the terminal with chmod +x nsz-cli-macos or chmod +x nsz-gui-macos. After trying to run the program you will be stopped by security. Go to System Settings > Privacy & Security then scroll down and choose to allow running the program.
Requires Python 3.6+.
This tool can be run from the source code.
pip3 install -r requirements.txt to install the requirements for the CLI only, or pip3 install -r requirements-gui.txt to install the requirements for the CLI and GUI.python3 nsz.py to start the program.Requires Python 3.6+.
Use the following command to install the console-only version:
pip3 install --upgrade nsz
Use the following command to install the GUI version:
pip3 install --upgrade nsz[gui]
NSZ is available as a Docker container with multi-architecture support for easy deployment and usage without needing to install Python.
The container provides:
For complete Docker setup, build instructions, and usage examples see container/README.md.
Quick example:
# Build for local testing
make -C container build-single-arch
# Use with your Nintendo Switch keys
docker run --rm -v "$(pwd)":/data -v "$HOME/.switch/prod.keys":/root/.switch/prod.keys nsz-tool:latest application.nsp
Comprehensive lists of command line parameters and usage examples are in the dedicated usage documentation.
To view all possible flags and their descriptions check the Usage section.
Automated bulk file operation examples are in scripts.
Explanations of the file formats introduced by NSZ are found in the formats documentation.
If you are interested in reporting/fixing issues and contributing directly to the code base, please see CONTRIBUTING.md for more information on how to get started.
The Swiss mirror will be the new home in case GitHub ever takes down this repository. Please bookmark it.
NSZ pip package: https://pypi.org/project/nsz/
Forum thread: https://gbatemp.net/threads/nsz-homebrew-compatible-nsp-xci-compressor-decompressor.550556/
Licensed under the MIT license.
Overall
Maintained
Code review
PyPI
Latest release
Releases this year
766 followers · starred Jul 2025
11,118 followers · starred Nov 2025
155 followers · starred Mar 2026
66 followers · starred Apr 2025