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

# Mirror - Supported sinks

Sinks define the destination of your data. Mirror supports a variety of sinks, from traditional databases optimized for querying and analysis to intermediate storage layers like Kafka and S3 that facilitate further integration into your data stack.

## Available Sinks

Mirror supports a wide range of sinks optimized for different use cases, from real-time querying to analytics and data integration:

<CardGroup cols="2">
  <Card title="Postgres" icon="database" href="/mirror/sinks/postgres">
    Postgres stands out with its advanced features, extensibility, and strong
    ACID compliance. Includes hosted option via NeonDB.
  </Card>

  <Card title="MySQL" icon="database" href="/mirror/sinks/mysql">
    MySQL stands out with its advanced features, extensibility, and strong
    ACID compliance.
  </Card>

  <Card title="ClickHouse" icon="chart-column-stacked" href="/mirror/sinks/clickhouse">
    ClickHouse delivers exceptional performance for OLAP queries with its
    columnar storage format.
  </Card>

  <Card title="Elasticsearch" icon="search" href="/mirror/sinks/elasticsearch">
    Elasticsearch is a powerful tool for real-time search and analytics on large
    datasets.
  </Card>

  <Card title="Timescale" icon="chart-candlestick" href="/mirror/sinks/timescale">
    Timescale offers powerful time-series data management and analytics with
    PostgreSQL compatibility.
  </Card>

  <Card title="Kafka" icon="list-start" href="/mirror/sinks/kafka">
    Kafka excels in handling high-throughput, real-time data streams with strong
    fault tolerance.
  </Card>

  <Card title="Object Storage (S3/GCS/R2)" icon="database" href="/mirror/sinks/object-storage">
    Object storage solutions like AWS S3, Google Cloud Storage, and Cloudflare R2 offer unparalleled scalability and durability for storing vast amounts of data.
  </Card>

  <Card title="AWS SQS" icon="aws" href="/mirror/sinks/aws-sqs">
    AWS SQS provides reliable message queuing for decoupling distributed systems
    with ease.
  </Card>

  <Card title="Webhook" icon="webhook" href="/mirror/sinks/webhook">
    A Webhook sink enables sending data to an external service via HTTP. This allows you to output pipeline results to your application server, to a third-party API, or a bot.
  </Card>
</CardGroup>

### What should I use?

#### For APIs for apps

For sub-second queries, typically you would choose a database that has row-based storage (i.e. it stores each row as it is instead of applying any sort of compression).

The drawbacks are that they take more space. This means large, non-indexed scans can take longer and storage costs can be higher.

1. [Postgres](/mirror/sinks/postgres) is the gold standard for application databases. It can scale almost infinitely with some management (You can use a Goldsky hosted version so you don't have to worrry about scaling), and can support very fast point-lookups with proper indexing.

   If you require super fast lookups by `transaction_hash` or a specific column, Postgres is a very safe choice to start with. It's great as a backend for live data APIs.

   However, it can be slow for analytics queries with a lot of aggregations. For that, you may want to look for an analytical database.

   Great hosted solutions for Postgres include [NeonDB](https://neon.tech/), [AWS Aurora](https://aws.amazon.com/rds/aurora/), and [GCP CloudSQL](https://cloud.google.com/sql).
2. [Elasticsearch](/mirror/sinks/elasticsearch) is a no-sql database that allows for blazing fast lookups and searches. Elasticsearch is built around super-fast non-indexed scanning, meaning it can look at every single record to find the one you want. As a result, you can do queries like fuzzy matches and wildcard lookups with millisecond latency.

   Common applications include search on multiple columns, ‘instant' auto-complete, and more.

#### For Analytics

1. [ClickHouse](/mirror/sinks/clickhouse) is a very efficient choice for storage. You can store the entire Ethereum blockchain and pay around \$50 in storage.

   We recommend considering ClickHouse as an alternative to Snowflake or BigQuery - it supports many of the same use cases, and has additional features such as materialized views. We've seen our customers save tens of thousands of dollars using Goldsky and ClickHouse as a solution.

   The pricing for managing ClickHouse is based on storage cost, then compute cost. The compute cost is constant and isn't based on the amount of data scanned, so you can run concurrent queries without increasing cost.
