> ## Documentation Index
> Fetch the complete documentation index at: https://cockroachlabs.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Visualize CockroachDB Schemas with DBeaver

export const InternalLink = ({version, path = "", children, ...props}) => {
  let detectedVersion = version || "stable";
  if (typeof window !== 'undefined' && !version) {
    const match = window.location.pathname.match(/\/docs\/([^/]+)/);
    if (match) {
      detectedVersion = match[1];
    }
  }
  const normalizedPath = path.startsWith("/") ? path.slice(1) : path;
  return <a href={`/docs/${detectedVersion}/${normalizedPath}`} {...props}>
      {children}
    </a>;
};

The [DBeaver database tool](https://dbeaver.io/) is a tool that completely integrates with CockroachDB to provide a GUI for managing your database.

According to the [DBeaver website](https://dbeaver.io/):

> DBeaver is a cross-platform Database GUI tool for developers, SQL programmers, database administrators, and analysts.

In this tutorial, you'll work through the process of using DBeaver with a secure CockroachDB cluster.

<Tip>
  For more information about using DBeaver, see the [DBeaver documentation](https://dbeaver.io/docs).

  If you run into problems, please file an issue on the [DBeaver issue tracker](https://github.com/dbeaver/dbeaver/issues).

  For information on using DBeaver with CockroachDB Cloud, see [this blog post](https://paul-logston.medium.com/setting-up-a-sql-gui-with-cockroachdb-a9fd5fe15d9d).
</Tip>

## Before You Begin

To work through this tutorial, take the following steps:

* <InternalLink path="install-cockroachdb">Install CockroachDB</InternalLink> and <InternalLink path="secure-a-cluster">start a secure cluster</InternalLink>.
* Download a copy of [DBeaver](https://dbeaver.io/download) version 5.2.3 or greater.

## Step 1. Start DBeaver and connect to CockroachDB

1. Start DBeaver, and select **Database > New Connection** from the menu. In the dialog that appears, select **CockroachDB** from the list.

   <img src="https://mintcdn.com/cockroachlabs/XMLGfz_GeuktxZzJ/images/v25.2/dbeaver-01-select-cockroachdb.png?fit=max&auto=format&n=XMLGfz_GeuktxZzJ&q=85&s=3c9b9be8d52afd5a873744d475c351b2" alt="DBeaver - Select CockroachDB" width="1626" height="1290" data-path="images/v25.2/dbeaver-01-select-cockroachdb.png" />

2. Click **Next**. The **Connection Settings** dialog displays.

3. In the **Database** field, enter `movr`.

   <img src="https://mintcdn.com/cockroachlabs/XMLGfz_GeuktxZzJ/images/v25.2/dbeaver-02-cockroachdb-connection-settings.png?fit=max&auto=format&n=XMLGfz_GeuktxZzJ&q=85&s=5e3c9b70618a1bb23ff040ddcb484ea3" alt="DBeaver - CockroachDB connection settings" width="1402" height="1220" data-path="images/v25.2/dbeaver-02-cockroachdb-connection-settings.png" />

## Step 2. Update the connection settings

1. Click the **SSL** tab.

   <img src="https://mintcdn.com/cockroachlabs/XMLGfz_GeuktxZzJ/images/v25.2/dbeaver-03-ssl-tab.png?fit=max&auto=format&n=XMLGfz_GeuktxZzJ&q=85&s=1b39e68018b55df36377174ebb5efd5d" alt="DBeaver - SSL tab" width="1630" height="1286" data-path="images/v25.2/dbeaver-03-ssl-tab.png" />

2. Check the **Use SSL** checkbox as shown, and fill in the text areas as follows:
   * **Root certificate**: Use the `ca.crt` file you generated for your secure cluster.
   * **SSL certificate**: Use a client certificate generated from your cluster's root certificate. For the root user, this will be named `client.root.crt`. For additional security, you may want to create a new database user and client certificate just for use with DBeaver.
   * **SSL certificate key**: Because DBeaver is a Java application, you will need to transform your key file to the `*.pk8` format using an [OpenSSL command](https://wiki.openssl.org/index.php/Command_Line_Utilities#pkcs8_.2F_pkcs5) like the one shown in the following snippet. Once you have created the file, enter its location here. In this example, the filename is `client.root.pk8`.

     ```console theme={"theme":{"light":"catppuccin-mocha","dark":"catppuccin-mocha"}}
     $ openssl pkcs8 -topk8 -inform PEM -outform DER -in client.root.key -out client.root.pk8 -nocrypt
     ```

3. Select **verify-ca** or **verify-full** from the **SSL mode** dropdown. There is no need to set the **SSL Factory**; you can let DBeaver use the default.

## Step 3. Test the connection settings

1. Click **Test Connection...**. If you need a driver, the following dialog displays:

   <img src="https://mintcdn.com/cockroachlabs/XMLGfz_GeuktxZzJ/images/v25.2/dbeaver-06-download-driver.png?fit=max&auto=format&n=XMLGfz_GeuktxZzJ&q=85&s=1c300ad072bab8cd4bace1c9bf3f19ef" alt="DBeaver - download driver dialog" width="1362" height="1068" data-path="images/v25.2/dbeaver-06-download-driver.png" />

2. Click **Download**.

   After the driver downloads, if the connection was successful, you will see a **Connected** dialog.

   <img src="https://mintcdn.com/cockroachlabs/XMLGfz_GeuktxZzJ/images/v25.2/dbeaver-04-connection-success-dialog.png?fit=max&auto=format&n=XMLGfz_GeuktxZzJ&q=85&s=d971163a805dabbbcc0b2e089a72cecb" alt="DBeaver - connection success dialog" width="424" height="244" data-path="images/v25.2/dbeaver-04-connection-success-dialog.png" />

3. Click **OK** to dismiss the dialog.

## Step 4. Start using DBeaver

Expand the **movr** database node and navigate to the **rides** table.

<img src="https://mintcdn.com/cockroachlabs/XMLGfz_GeuktxZzJ/images/v25.2/dbeaver-05-movr.png?fit=max&auto=format&n=XMLGfz_GeuktxZzJ&q=85&s=b511c665b0cb5ce54333b503a51068bf" alt="DBeaver - CockroachDB with the movr database" width="2514" height="1704" data-path="images/v25.2/dbeaver-05-movr.png" />

For more information about using DBeaver, see the [DBeaver documentation](https://dbeaver.io/docs).

## Report Issues with DBeaver & CockroachDB

If you run into problems, please file an issue on the [DBeaver issue tracker](https://github.com/dbeaver/dbeaver/issues), including the following details about the environment where you encountered the issue:

* CockroachDB version ( <InternalLink path="cockroach-version">`cockroach version`</InternalLink> )
* DBeaver version
* Operating system
* Steps to reproduce the behavior
* If possible, a trace of the SQL statements sent to CockroachDB while the error is being reproduced using <InternalLink path="logging-use-cases#sql_exec">SQL query logging</InternalLink>.

## See Also

* [DBeaver documentation](https://dbeaver.io/docs)
* [DBeaver issue tracker](https://github.com/dbeaver/dbeaver/issues)
* <InternalLink path="connection-parameters">Client connection parameters</InternalLink>
* <InternalLink path="third-party-database-tools">Third-Party Database Tools</InternalLink>
* <InternalLink path="learn-cockroachdb-sql">Learn CockroachDB SQL</InternalLink>
