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

# Services

> Install and manage database services from the CLI.

Manage database services installed inside your pods. Aliases: `service`, `svc`.

## List Services

```bash theme={null}
instapods services list my-app
```

Shows all installed services with their status, type, port, and version. Failed services display their error message inline.

## Install a Service

```bash theme={null}
instapods services add my-app -s mysql
instapods services add my-app -s postgresql
instapods services add my-app -s redis
```

Alias: `services install`.

### Wait for Installation

Service installation runs in the background (typically 8-15 seconds). Use `-w` to block until ready:

```bash theme={null}
instapods services add my-app -s mysql -w
```

If installation fails, the `-w` flag shows the actual error reason instead of just "failed".

### Install Flags

| Flag            | Description                                  | Default  |
| --------------- | -------------------------------------------- | -------- |
| `-s, --service` | Service type: `mysql`, `postgresql`, `redis` | Required |
| `-w, --wait`    | Wait until service is running                | `false`  |
| `--timeout`     | Max seconds to wait (with `-w`)              | `120`    |

```bash theme={null}
# Install with extended timeout
instapods services add my-app -s postgresql -w --timeout 180
```

## Remove a Service

```bash theme={null}
# With confirmation prompt
instapods services remove my-app -s mysql

# Skip confirmation
instapods services remove my-app -s mysql -f
```

Aliases: `rm`, `delete`, `uninstall`.

| Flag            | Description              | Default  |
| --------------- | ------------------------ | -------- |
| `-s, --service` | Service type to remove   | Required |
| `-f, --force`   | Skip confirmation prompt | `false`  |

<Warning>
  Removing a service deletes all its data permanently. There is no undo.
</Warning>

## Get Credentials

```bash theme={null}
instapods services creds my-app -s mysql
```

Aliases: `credentials`, `info`.

Displays connection details and a ready-to-use connection command:

```
Host:     localhost
Port:     3306
Username: instapod
Password: (auto-generated)
Database: instapod

Connect: mysql -u instapod -p<password> instapod
```

Connection commands vary by service:

* **MySQL**: `mysql -u instapod -p<password> instapod`
* **PostgreSQL**: `PGPASSWORD=<password> psql -U instapod -d instapod`
* **Redis**: `redis-cli`

## Available Services

| Service    | Flag Value   | Port | Version |
| ---------- | ------------ | ---- | ------- |
| MySQL      | `mysql`      | 3306 | 8.0     |
| PostgreSQL | `postgresql` | 5432 | 14      |
| Redis      | `redis`      | 6379 | 7       |

<Note>
  Services require the **Build plan or higher**. Launch plan pods cannot install services. Upgrade your pod's plan with `instapods pods resize my-app --plan build` to enable services.
</Note>

See the [Services section](/services/overview) for detailed usage guides for each database.
