Upgrade the Snyk CLI
How to upgrade the Snyk CLI to stay secure and current
Upgrade the Snyk CLI regularly to maintain a secure environment. Snyk releases frequent updates to provide the latest vulnerability definitions, introduce new features, and ensure compatibility with package managers. Outdated versions can limit scanning capabilities, trigger false positives, or cause inaccurate results.
Select the upgrade command that matches your original installation method.
Package managers
Docker
Upgrade the Snyk CLI in a Docker environment by pulling the latest image from Docker Hub. This action overwrites the local cached image:
GitHub actions
The Snyk GitHub Action type in your workflow determines how the Snyk CLI updates.
Using the @master branch tag (for example, uses: snyk/actions/node@master) ensures your pipeline pulls the latest version of the GitHub Action. This tag does not dictate the CLI version.
Snyk updates the CLI version in one of two ways:
Language-specific actions (Docker based)
Language-specific actions (such as Node and Python) run using Snyk Docker images. These images use the latest version of the Snyk CLI by default.
Snyk setup action (binary installation)
The Snyk Setup action installs the CLI directly from a binary. By default, this action downloads and uses the latest version of the Snyk CLI.
Unlike Docker-based actions, the Snyk Setup action allows you to pin a specific CLI version to prevent automatic updates. Use the version input to specify the version:
Direct binary download
Update the Snyk CLI manually when using standalone executables. To update, download the latest binary and replace the existing executable. For example, on Linux or MacOS, run the curl download command again.
For more information including the download commands, visit Install the Snyk CLI.
Last updated
Was this helpful?

