> For the complete documentation index, see [llms.txt](https://docs.zerve.ai/zerve-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.zerve.ai/zerve-docs/data-and-assets/connections.md).

# Data connections

Connect Zerve to your databases and data platforms.

A **data connection** stores the details Zerve needs to reach a database or data platform, so your notebooks and agents can query it without anyone pasting credentials into code.

## Supported connections

| Connection                                                          | How it signs in                        |
| ------------------------------------------------------------------- | -------------------------------------- |
| [PostgreSQL](/zerve-docs/data-and-assets/connections/postgresql.md) | Username and password                  |
| [MySQL](/zerve-docs/data-and-assets/connections/mysql.md)           | Username and password                  |
| [MariaDB](/zerve-docs/data-and-assets/connections/mariadb.md)       | Username and password                  |
| [Snowflake](/zerve-docs/data-and-assets/connections/snowflake.md)   | Username with a password or a key pair |
| [Databricks](/zerve-docs/data-and-assets/connections/databricks.md) | Access token                           |
| [BigQuery](/zerve-docs/data-and-assets/connections/bigquery.md)     | Google service account key             |
| [KX (kdb+)](/zerve-docs/data-and-assets/connections/kx.md)          | Username and password                  |
| [Ocient](/zerve-docs/data-and-assets/connections/ocient.md)         | Username and password                  |
| [Weaviate](/zerve-docs/data-and-assets/connections/weaviate.md)     | API key (optional)                     |
| [Domo](/zerve-docs/data-and-assets/connections/domo.md)             | Client ID and secret                   |

## Creating a connection

{% stepper %}
{% step %}

### Open Connections

Go to **Assets → Connections**, and create a new connection.
{% endstep %}

{% step %}

### Choose the type and name it

Choose the connection type, and give it a name. See [Naming rules](#naming-rules).
{% endstep %}

{% step %}

### Enter the details

Fill in the details for that type of connection. See the page for your connection type.
{% endstep %}

{% step %}

### Attach it to a notebook

Attach the connection to the notebooks that need it.
{% endstep %}
{% endstepper %}

## Naming rules

A connection's name is how it's referred to in code, so it must be a valid name in code:

* Start with a **letter or underscore**
* Use only **letters, numbers and underscores**
* Up to 255 characters

| Valid                | Not valid                          |
| -------------------- | ---------------------------------- |
| `prod_warehouse`     | `prod-warehouse` (hyphen)          |
| `snowflake_research` | `Snowflake Research` (space)       |
| `_staging`           | `2024_data` (starts with a number) |

## Using a connection in a notebook

Attach the connection to a notebook to use it there. A connection can be attached to many notebooks, and the connection's page shows every notebook using it.

When you attach a connection, you can give it an **alias**: a different name to use in that notebook.

## Credentials stay hidden

Passwords, tokens and keys are **never shown back** to anyone after you save them, including the person who created the connection. They're only passed to your code when a block runs.

## Connecting to databases with IP allowlists

If your database only accepts connections from approved IP addresses, it needs to allow Zerve's outbound IP address. If your organization runs Zerve in its own AWS account, this is your account's NAT gateway IP. See [AWS QuickStart](/zerve-docs/self-hosting/aws-quickstart.md#connecting-to-your-databases).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.zerve.ai/zerve-docs/data-and-assets/connections.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
