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

# Getting Started with Sequin

> Learn how to install and configure Sequin in minutes using Docker Compose. Set up your Postgres CDC pipeline with minimal effort.

You can start running Sequin quickly with Docker Compose.

## Prerequisites

You'll need Docker and Docker Compose installed.

## Quick start

The easiest way to get started with Sequin is with our [Docker Compose file](https://github.com/sequinstream/sequin/blob/main/docker/docker-compose.yaml). This file starts a Postgres database, Redis instance, and Sequin server.

<Steps>
  <Step title="Create directory and start services">
    1. Download [sequin-docker-compose.zip](https://github.com/sequinstream/sequin/releases/latest/download/sequin-docker-compose.zip).
    2. Unzip the file.
    3. Navigate to the unzipped directory and start the services:

    ```bash theme={null}
    cd sequin-docker-compose && docker compose up -d
    ```

    <AccordionGroup>
      <Accordion title="Alternative: Download with curl">
        ```bash theme={null}
        curl -L https://github.com/sequinstream/sequin/releases/latest/download/sequin-docker-compose.zip -o sequin-docker-compose.zip \
          && unzip sequin-docker-compose.zip && rm sequin-docker-compose.zip
        cd sequin-docker-compose && docker compose up -d
        ```
      </Accordion>

      <Accordion title="Alternative: Clone the repository">
        ```bash theme={null}
        git clone git@github.com:sequinstream/sequin.git
        cd sequin/docker
        docker compose up -d
        ```
      </Accordion>
    </AccordionGroup>
  </Step>

  <Step title="Verify services are running">
    Check that Sequin is running using `docker ps`:

    ```bash theme={null}
    docker ps
    ```

    You should see output like the following:

    ```
    CONTAINER ID   IMAGE                           COMMAND                  CREATED          STATUS                    PORTS                              NAMES
    bd5c458cabde   sequin/sequin:latest            "/scripts/start_comm…"   11 seconds ago   Up 9 seconds              4000/tcp, 0.0.0.0:7376->7376/tcp   sequin-sequin-1
    3bacd89765e7   grafana/grafana                 "/run.sh"                11 seconds ago   Up 11 seconds             0.0.0.0:3000->3000/tcp             sequin-sequin_grafana-1
    3ad41319a66c   postgres:16                     "docker-entrypoint.s…"   11 seconds ago   Up 11 seconds (healthy)   0.0.0.0:7377->5432/tcp             sequin-sequin_postgres-1
    6139a5fc4e80   redis:7                         "docker-entrypoint.s…"   11 seconds ago   Up 11 seconds             0.0.0.0:7378->6379/tcp             sequin-sequin_redis-1
    7e07a5b052de   prom/prometheus                 "/bin/prometheus --c…"   11 seconds ago   Up 11 seconds             0.0.0.0:9090->9090/tcp             sequin-sequin_prometheus-1
    ```

    <Check>
      Sequin, Postgres, Redis, Prometheus, and Grafana should be up and running (status: `Up`).
    </Check>
  </Step>

  <Step title="Login to Sequin">
    Open your browser and navigate to [`http://localhost:7376`](http://localhost:7376).

    Sign in with the default credentials:

    * Username: `admin@sequinstream.com`
    * Password: `sequinpassword!`
  </Step>

  <Step title="Create a sink">
    <Check>
      You're in! Create a sink by following one of our quickstart guides:
    </Check>

    <CardGroup cols={2}>
      <Card title="Webhooks" icon="webhook" href="/quickstart/webhooks">
        Get started with real-time updates via webhooks.
      </Card>

      <Card title="Kafka" icon="bolt" href="/quickstart/kafka">
        Set up CDC streaming with Apache Kafka.
      </Card>

      <Card title="Typesense" icon="folder-magnifying-glass" href="/quickstart/typesense">
        Stream changes to Typesense.
      </Card>

      <Card title="Meilisearch" icon="folder-magnifying-glass" href="/quickstart/meilisearch">
        Stream changes to Meilisearch.
      </Card>

      <Card title="Elasticsearch" icon="file-magnifying-glass" href="/quickstart/elasticsearch">
        Stream changes to Elasticsearch.
      </Card>

      <Card title="Redis Stream" icon="database" href="/quickstart/redis-stream">
        Stream changes using Redis pub/sub.
      </Card>

      <Card title="RabbitMQ" icon="rabbit" href="/quickstart/rabbitmq">
        Get started with RabbitMQ messaging.
      </Card>

      <Card title="NATS" icon="network-wired" href="/quickstart/nats">
        Stream changes using NATS messaging.
      </Card>

      <Card title="Redpanda" icon="paw" href="/quickstart/redpanda">
        Set up CDC with Redpanda streaming.
      </Card>

      <Card title="Azure Event Hubs" icon="microsoft" href="/quickstart/azure-event-hubs">
        Stream changes using Azure Event Hubs.
      </Card>

      <Card title="GCP Pub/Sub" icon="google" href="/quickstart/gcp-pubsub">
        Get started with Google Cloud Pub/Sub.
      </Card>

      <Card title="AWS SQS" icon="aws" href="/quickstart/sqs">
        Stream changes using AWS Simple Queue Service.
      </Card>

      <Card title="Sequin Stream" icon="signal-stream" href="/quickstart/sequin-stream">
        Use Sequin's native streaming protocol.
      </Card>
    </CardGroup>
  </Step>

  <Step title="View metrics in Grafana">
    Sequin exports  [various metrics](/reference/metrics) in Prometheus format.

    Using the Grafana service from Docker Compose, you can view our [example dashboard here](http://localhost:3000/d/behuozial454wc/sequin).

    Sign in with Grafana's default credentials:

    * Username: `admin`
    * Password: `admin`
  </Step>
</Steps>

## Using your own database

### Using existing Postgres

Sequin uses a Postgres database for configuration and to assist with its change data capture process.

<Note>
  These `PG_*` variables configure Sequin's internal Postgres database. The Postgres databases you want to stream from are configured separately in [`sequin.yaml`](/reference/sequin-yaml#database-configuration).
</Note>

We recommend creating a new logical database for Sequin in your existing Postgres instance:

```sql theme={null}
create database {DB-NAME};
```

Then, modify your `docker-compose.yaml`:

1. Remove the `postgres` service section
2. Update the Sequin service configuration:

```yaml theme={null}
services:
  sequin:
    environment:
      - PG_PORT=<port>
      - PG_HOSTNAME=<hostname>
      - PG_DATABASE=<database>
      - PG_USERNAME=<username>
      - PG_PASSWORD=<password>
```

### Using existing Redis

Sequin uses Redis to assist with its change data capture process.

If you have an existing Redis instance:

1. Remove the `redis` service section
2. Update the Sequin service configuration:

```yaml theme={null}
services:
  sequin:
    environment:
      - REDIS_URL=<url>
```

## Adding to an existing project

### Using Docker Compose include (recommended)

The cleanest way to add Sequin to an existing project is using Docker Compose's `include` functionality:

1. Download the Sequin's [docker-compose.yaml](https://github.com/sequinstream/sequin/blob/main/docker/docker-compose.yaml).

2. Add an `include` section to your existing `docker-compose.yaml`:

```yaml theme={null}
include:
  - sequin-docker-compose.yaml

services:
  # your existing services...
```

This approach keeps your main compose file clean while providing all of Sequin's services.

### Adding Sequin service directly

Alternatively, you can add Sequin directly to your existing Docker Compose file by adding a `sequin` service:

```yaml theme={null}
services:
  ...
  sequin:
    image: sequin/sequin:latest
    ports:
      - "7376:7376"
    environment:
      - PG_PORT=<port>
      - PG_HOSTNAME=postgres
      - PG_DATABASE=sequin
      - PG_USERNAME=postgres
      - PG_PASSWORD=postgres
      - REDIS_URL=<url>
      - SECRET_KEY_BASE=wDPLYus0pvD6qJhKJICO4dauYPXfO/Yl782Zjtpew5qRBDp7CZvbWtQmY0eB13If
      - VAULT_KEY=2Sig69bIpuSm2kv0VQfDekET2qy8qUZGI8v3/h3ASiY=
    depends_on:
      - postgres
      - redis
```

## Preparing for production

For more configuration options and steps for deploying to production, see the [Configuration Reference](/reference/configuration).

For production deployment on AWS using Terraform, see the [deployment directory](https://github.com/sequinstream/sequin/tree/main/deployment) which contains infrastructure-as-code templates for deploying Sequin on AWS ECS.
