# Databases

> The Project tab that lists your app's databases on AirHost and which service uses each one.

Source: https://air.build/docs/screens/platform/databases/

The **Databases** tab lists your app's databases on AirHost, how many there are and how many a service uses. Open a database to browse its tables and run SQL, or delete one no service uses.

> [!NOTE]
> **New Database** is only on the Mac.

## Open it

**iPhone**

Open the Project's chat, tap the tabs button (four squares) in the top-right corner, then tap **Databases** in the list under the tab cards.

**Mac**

Open the Project's chat and choose **View › Go To › Databases**, or open the inspector (**View › Show Inspector**, ⌥⌘I), click **New Tab** (**+**) and click **Databases**.

## What's on it

| Part | What it shows or does |
| --- | --- |
| **Databases** | How many databases the app has. |
| **In Use** | How many of them a service uses. |
| Database rows | One per database: its name, then "Used by _service_" or "Not connected to a service", and **In Use** at the end when a service uses it. Tap a row for its [Database page](https://air.build/docs/screens/platform/database-page/). |
| **New Database** (Mac) | In the inspector's bar under the page. Opens [New Database](https://air.build/docs/screens/platform/new-database/). |

A database stays when the service using it is removed.

Pull down on the page (iPhone, iPad) to read it again.

### The row's menu

Touch and hold a database's row (on the Mac, right-click it):

| Item | What it does |
| --- | --- |
| **Open Database** | Opens its [Database page](https://air.build/docs/screens/platform/database-page/). |
| **Delete Database** | Deletes it, after you confirm. Dimmed while a service uses it. |

There's no undo. **Delete Database** is dimmed while a service uses the database. To delete it, first remove that service (see [Remove the service](https://air.build/docs/screens/platform/service-page/#remove-the-service)), or ask your Agents in the chat.

## Before there are databases

While the app has none, the tab says **Store This App’s Data**: "Keep the app’s data in a database on AirBuild’s hosting service.", with "Stays when the service using it is removed" and "Browse tables and run SQL from here". Tap **Ask Agents to Add** and the app asks first: **Ask Agents to Add**, with the message it will send, "Add a database to the app". Tap **Cancel** to send nothing, or **Send** to send it. In the Project's chat, the message appears as your own, with a strip under it showing AirHost's image, its name and an arrow; tap the strip to open [Hosting](https://air.build/docs/screens/platform/hosting/). The chat comes to the front. Back on the tab, it says "Sent to the project chat" and offers **Open Chat**.

## Messages

| Message | When | What to do |
| --- | --- | --- |
| The reason, with **Try Again** | The list couldn't be read. The numbers show "—". | Tap **Try Again**. |
| **That Didn’t Work**, with the reason | Deleting was refused or AirBuild couldn't be reached. | Tap **OK** and try again. |
| "Select a project in the sidebar to manage its app services." | The tab isn't showing a Project. | Pick a Project. |
