{"id":9976,"library":"nbzip","title":"nbzip Jupyter Notebook Extension","description":"nbzip is a Jupyter Notebook extension that allows users to compress and download all files within a specified directory directly from the Jupyter interface. It provides a convenient way to archive and retrieve project files from the Jupyter server's filesystem. The current version is 0.1.0. Its release cadence is low, as it's a stable, focused utility.","status":"active","version":"0.1.0","language":"en","source_language":"en","source_url":"https://github.com/data-8/nbzip","tags":["jupyter","notebook","jupyterlab","extension","compression","archive","download","server-extension"],"install":[{"cmd":"pip install nbzip","lang":"bash","label":"Install nbzip Python package"},{"cmd":"jupyter server extension enable --py nbzip --sys-prefix","lang":"bash","label":"Enable the Jupyter server extension"}],"dependencies":[],"imports":[{"note":"Functionality is accessed via the Jupyter UI after enabling the extension and restarting Jupyter.","symbol":"No direct user-facing symbols","correct":"nbzip is primarily a Jupyter server extension and does not expose commonly imported Python symbols for end-user programmatic use."}],"quickstart":{"code":"pip install nbzip\njupyter server extension enable --py nbzip --sys-prefix\n# Restart Jupyter Notebook/Lab if it's running to apply changes.","lang":"bash","description":"This sequence installs the `nbzip` package and enables it as a Jupyter server extension. After enabling and restarting your Jupyter server, you will find a new 'Download directory (.zip)' option in the file menu of any Jupyter Notebook or JupyterLab interface when navigating directories, or an 'Archive' button in JupyterLab's file browser."},"warnings":[{"fix":"Run `jupyter server extension enable --py nbzip --sys-prefix` after `pip install nbzip` and restart your Jupyter server.","message":"nbzip is a Jupyter server extension and needs to be explicitly enabled after installation for its functionality to appear in the Jupyter UI. Installing the package alone is not sufficient.","severity":"gotcha","affected_versions":"All versions (0.1.0)"},{"fix":"Understand that the operations are server-side. Ensure necessary files are present on the server where Jupyter is running before attempting to archive them.","message":"nbzip operates on the Jupyter server's filesystem. If your Jupyter environment is remote (e.g., a cloud instance), the files compressed and downloaded will be from that remote server, not your local machine.","severity":"gotcha","affected_versions":"All versions (0.1.0)"},{"fix":"Utilize the UI options (File menu or Archive button in JupyterLab) to access nbzip's functionality, rather than attempting to `import nbzip` and call functions directly in Python code.","message":"nbzip does not provide Python symbols for direct programmatic access to its compression features within a Python script. Its primary interface is through the Jupyter Notebook or JupyterLab user interface.","severity":"gotcha","affected_versions":"All versions (0.1.0)"}],"env_vars":null,"last_verified":"2026-04-17T00:00:00.000Z","next_check":"2026-07-16T00:00:00.000Z","problems":[{"fix":"Run `pip install nbzip` to install the package.","cause":"The `nbzip` Python package has not been installed in the active Python environment associated with your Jupyter server.","error":"ModuleNotFoundError: No module named 'nbzip'"},{"fix":"First, ensure it's installed (`pip install nbzip`). Then, enable it by running `jupyter server extension enable --py nbzip --sys-prefix` and finally restart your Jupyter Notebook or JupyterLab server.","cause":"The `nbzip` Jupyter server extension has been installed but not enabled, or the Jupyter server has not been restarted after enabling.","error":"nbzip functionality (e.g., 'Download directory (.zip)' option) is not visible in Jupyter Notebook/Lab."},{"fix":"Ensure the Jupyter server process has sufficient read/write permissions to the directories you are attempting to archive. This might involve adjusting file system permissions (e.g., `chmod`) or running Jupyter with appropriate user privileges.","cause":"The user running the Jupyter server process (and thus nbzip) lacks the necessary read/write permissions for the target directories on the server's filesystem.","error":"Permission denied when nbzip attempts to create a zip file or access directories."}]}