docs/content/stable/releases/yugabyte-clients.md
YugabyteDB ships with command line interface (CLI) shells for interacting with each YugabyteDB API.
| Client | API | Description |
|---|---|---|
| ysqlsh | YSQL | SQL shell for interacting with YugabyteDB using PostgreSQL-compatible YSQL API. |
| ycqlsh | YCQL | CQL shell for interacting with YugabyteDB using Cassandra-compatible YCQL API. |
Clients work best with servers of the same or an older major version. If you are running multiple versions of YugabyteDB, use the newest version of the client to connect. You can keep and use the matching version of a client to use with each version of YugabyteDB, but in practice, this shouldn't be necessary. For best results, use the latest client.
While the general functionality of running SQL statements and displaying query results should also work with servers of a newer major version, this cannot be guaranteed in all cases. In particular, due to the change from PostgreSQL 11 to 15 in YugabyteDB 2.25, use only the latest client to avoid compatibility issues.
The YugabyteDB clients are installed with YugabyteDB and located in the bin directory of the YugabyteDB home directory.
You can also install a standalone version using any of the following methods:
<ul class="nav nav-tabs nav-tabs-yb"> <li> <a href="#macosx86" class="nav-link active" id="macosx86-tab" data-bs-toggle="tab" role="tab" aria-controls="macosx86" aria-selected="true"> <i class="fa-brands fa-apple" aria-hidden="true"></i> macOS x86 </a> </li> <li> <a href="#macosarm" class="nav-link" id="macosarm-tab" data-bs-toggle="tab" role="tab" aria-controls="macosarm" aria-selected="false"> <i class="fa-brands fa-apple" aria-hidden="true"></i> macOS ARM </a> </li> <li> <a href="#linuxx86" class="nav-link" id="linuxx86-tab" data-bs-toggle="tab" role="tab" aria-controls="linuxx86" aria-selected="false"> <i class="fa-brands fa-linux" aria-hidden="true"></i> Linux x86 </a> </li> <li> <a href="#linuxarm" class="nav-link" id="linuxarm-tab" data-bs-toggle="tab" role="tab" aria-controls="linuxarm" aria-selected="false"> <i class="fa-brands fa-linux" aria-hidden="true"></i> Linux ARM </a> </li> <li> <a href="#docker" class="nav-link" id="docker-tab" data-bs-toggle="tab" role="tab" aria-controls="docker" aria-selected="false"> <i class="fa-brands fa-docker" aria-hidden="true"></i> Docker </a> </li> </ul> <div class="tab-content"> <div id="macosx86" class="tab-pane fade show active" role="tabpanel" aria-labelledby="macosx86-tab">curl -OL https://downloads.yugabyte.com/releases/{{< yb-version version="stable" >}}/yugabyte-client-{{< yb-version version="stable" format="build">}}-darwin-x86_64.tar.gz
echo "$(curl -L https://downloads.yugabyte.com/releases/{{< yb-version version="stable" >}}/yugabyte-client-{{< yb-version version="stable" format="build">}}-darwin-x86_64.tar.gz.sha) *yugabyte-client-{{< yb-version version="stable" format="build">}}-darwin-x86_64.tar.gz" | shasum --check && \
tar xvfz yugabyte-client-{{< yb-version version="stable" format="build">}}-darwin-x86_64.tar.gz
cd yugabyte-client-{{< yb-version version="stable" >}}
curl -OL https://downloads.yugabyte.com/releases/{{< yb-version version="stable" >}}/yugabyte-client-{{< yb-version version="stable" format="build">}}-darwin-arm64.tar.gz
echo "$(curl -L https://downloads.yugabyte.com/releases/{{< yb-version version="stable" >}}/yugabyte-client-{{< yb-version version="stable" format="build">}}-darwin-arm64.tar.gz.sha) *yugabyte-client-{{< yb-version version="stable" format="build">}}-darwin-arm64.tar.gz" | shasum --check && \
tar xvfz yugabyte-client-{{< yb-version version="stable" format="build">}}-darwin-arm64.tar.gz
cd yugabyte-client-{{< yb-version version="stable" >}}
wget https://downloads.yugabyte.com/releases/{{< yb-version version="stable" >}}/yugabyte-client-{{< yb-version version="stable" format="build">}}-linux-x86_64.tar.gz
echo "$(curl -L https://downloads.yugabyte.com/releases/{{< yb-version version="stable" >}}/yugabyte-client-{{< yb-version version="stable" format="build">}}-linux-x86_64.tar.gz.sha) *yugabyte-client-{{< yb-version version="stable" format="build">}}-linux-x86_64.tar.gz" | shasum --check && \
tar xvfz yugabyte-client-{{< yb-version version="stable" format="build">}}-linux-x86_64.tar.gz
cd yugabyte-client-{{< yb-version version="stable" >}}
./bin/post_install.sh
wget https://downloads.yugabyte.com/releases/{{< yb-version version="stable" >}}/yugabyte-client-{{< yb-version version="stable" format="build">}}-linux-aarch64.tar.gz
echo "$(curl -L https://downloads.yugabyte.com/releases/{{< yb-version version="stable" >}}/yugabyte-client-{{< yb-version version="stable" format="build">}}-linux-aarch64.tar.gz.sha) *yugabyte-client-{{< yb-version version="stable" format="build">}}-linux-aarch64.tar.gz" | shasum --check && \
tar xvfz yugabyte-client-{{< yb-version version="stable" format="build">}}-linux-aarch64.tar.gz
cd yugabyte-client-{{< yb-version version="stable" >}}
./bin/post_install.sh
docker pull yugabytedb/yugabyte-client:latest
The YugabyteDB clients are released with every version of YugabyteDB. Only versions with client-specific changes are listed.
Documents the limitations of retry logic when using -c flag in ysqlsh command. {{<issue 21804>}}
Allows the deletion of the Cassandra role in ycqlsh without it regenerating upon cluster restart, by adding a flag to mark if the role was previously created. {{<issue 21057>}}