sq can be installed from source, via an install script, or via package managers for various platforms.

Quick install

Use in most cases other than Windows.

/bin/sh -c "$(curl -fsSL" determines what OS is in use, and attempts to use an appropriate package manager. The following have been tested:

Package ManagerOS / DistributionArchitecture
aptDebian-based (Ubuntu etc.)arm64 amd64
yumRPM-based (Rocky Linux, Fedora etc.)arm64 amd64
apkAlpine Linuxarm64 amd64
pacmanArch Linuxamd64
yayArch Linuxamd64
xbpsVoid Linuxarm64 amd64
brewmacOSarm64 amd64

You can view the source for on GitHub.

Shell completion

The install packages will generally install shell completion. Note that sq provides extensive completion functionality. If installing from source, it is highly recommended to manually install shell completion. For instructions:

sq completion --help


Requires Go.

go install


Pre-built binaries are available from GitHub releases.


brew install neilotoole/sq/sq


Requires scoop.

scoop bucket add sq
scoop install sq


Generally you can use

/bin/sh -c "$(curl -fsSL"

If you need more control over the install, consult the source code.


The image is preloaded with sq and a handful of related tools like jq.


# Shell into a one-time container.
$ docker run -it zsh

# Start detached (background) container named "sq-shell".
$ docker run -d --name sq-shell
# Shell into that container.
$ docker exec -it sq-shell zsh


Running sq in a Kubernetes environment is useful for DB migrations, as well as general data wrangling.

# Start pod named "sq-shell".
$ kubectl run sq-shell --image
# Shell into the pod.
$ kubectl exec -it sq-shell -- zsh


The sq version command reports on whether a new version is available.

$ sq version
sq v0.32.0    Update available: v0.33.0

Note that sq is still pre-v1.0.0. Occasionally a release introduces a breaking change.

Before upgrading, check the CHANGELOG or the notes for the latest release.

To upgrade, use the mechanism specific to the package manager for your system, e.g.:

brew upgrade sq