> ## Documentation Index
> Fetch the complete documentation index at: https://firebolt-aggregate-helm-docs-pr-4.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

> Learn about connecting Apache Superset to Firebolt Core.

# Apache Superset with Firebolt Core

[Apache Superset](https://superset.apache.org) is an open-source data exploration and visualization platform that empowers users to create interactive, shareable dashboards and charts for analyzing and presenting data. It supports a wide range of data sources and provides an intuitive, web-based interface for data exploration, slicing, and dicing, with features like dynamic filtering, pivot tables, and drag-and-drop functionality. Superset also offers a rich set of visualization options and can be extended through custom plugins, making it a versatile tool for data analysts and business users to gain insights from their data and collaborate effectively.

## Prerequisites

Superset can be installed in several ways, including using a pre-built [Docker container](https://superset.apache.org/docs/installation/docker-compose), building it from [source](https://superset.apache.org/docs/installation/pypi) or deploying via [Kubernetes Helm chart](https://superset.apache.org/docs/installation/kubernetes).

The easiest way to get started is to run Superset via Docker.

You will need:

* [Docker](https://www.docker.com/) and [Docker Compose](https://docs.docker.com/compose/).
* [Git](https://git-scm.com/).
* A running Firebolt Core instance. See the [Firebolt Core getting started guide](/firebolt-core/firebolt-core-get-started) for setup instructions.

## Quickstart

Follow this guide to setup Superset and connect it to your Firebolt Core instance.

### Setup Superset

1. Clone Superset's GitHub [repository](https://github.com/apache/superset)

```shell theme={null}
git clone https://github.com/apache/superset.git
```

2. Change directory to the root of the newly cloned repository and add the Firebolt driver

```shell theme={null}
cd superset
touch ./docker/requirements-local.txt
echo "firebolt-sqlalchemy" >> ./docker/requirements-local.txt
```

3. Run Superset via Docker Compose

```shell theme={null}
docker compose -f docker-compose-non-dev.yml up
```

4. (Optional) Verify firebolt driver is present in Superset container

```shell theme={null}
docker exec -it <container_name> bash
pip freeze | grep firebolt
```

You should see `firebolt-sqlalchemy` in the output.

Once your Superset is booted up you should be able to access it in `http://localhost:8088/`

<Note>
  For more installation details, refer to [Adding New Database Drivers in Docker](https://superset.apache.org/user-docs/6.0.0/configuration/databases/#installing-drivers-in-docker-images) in the Superset documentation.
</Note>

### Setup Firebolt Core connection

After the initial setup in Superset User Interface head to the **Settings -> Database connections** in the top right corner.

<img src="https://mintcdn.com/firebolt-aggregate-helm-docs-pr-4/4YB04dlilhUzJTlK/assets/images/superset-settings.png?fit=max&auto=format&n=4YB04dlilhUzJTlK&q=85&s=784a2984829bf0e950356fa9e1613b8e" alt="Database Connections" width="30%" data-path="assets/images/superset-settings.png" />

On the next screen, press the **+ Database** button and select Firebolt from the dropdown. If you don't see Firebolt in the list, please refer to the [Setup Superset](#setup-superset) section for instructions on how to install the Firebolt driver and verify that the driver is present.

<img src="https://mintcdn.com/firebolt-aggregate-helm-docs-pr-4/4YB04dlilhUzJTlK/assets/images/superset-connect-a-database.png?fit=max&auto=format&n=4YB04dlilhUzJTlK&q=85&s=51eccfa568ca4d799c70489ef9a67858" alt="Connect database" width="30%" data-path="assets/images/superset-connect-a-database.png" />

The connection expects a SQLAlchemy connection string of the form:

```
firebolt://{database}?url={url}
```

Where:

* `{database}` is your Firebolt Core database name (default is `firebolt`)
* `{url}` is the fully qualified URL where your Firebolt Core instance is hosted (default is `http://localhost:3473`)

For a local Firebolt Core instance running with default settings, the connection string would be:

```
firebolt://firebolt?url=http://localhost:3473
```

<Note>
  Unlike Firebolt Cloud, Firebolt Core does not require authentication credentials (client\_id, client\_secret, or account\_name) in the connection string since it's designed for self-hosted environments.
</Note>

<img src="https://mintcdn.com/firebolt-aggregate-helm-docs-pr-4/4YB04dlilhUzJTlK/assets/images/superset-firebolt-core-uri.png?fit=max&auto=format&n=4YB04dlilhUzJTlK&q=85&s=f4f7c786c4a38e9a7ffc6ebec4ecb614" alt="Credentials" width="30%" data-path="assets/images/superset-firebolt-core-uri.png" />

Click the **Test Connection** button to confirm things work end to end. If the connection looks good, save the configuration by clicking the **Connect** button in the bottom right corner of the modal window.
Now you're ready to start using Superset with Firebolt Core!

### Build your first chart

<Note>
  This section assumes you have loaded sample data into your Firebolt Core database. For guidance on loading data, see the [Firebolt Core data processing guide](/firebolt-core/firebolt-core-data-processing).
</Note>

Now that you've configured Firebolt Core as a data source, you can select specific tables (Datasets) that you want to see in Superset.

Go to **Data -> Datasets** and select **+ Dataset**. There you can select your sample table by specifying Firebolt as your Database, your schema and the table name you chose.

<img src="https://mintcdn.com/firebolt-aggregate-helm-docs-pr-4/4YB04dlilhUzJTlK/assets/images/superset-dataset-config.png?fit=max&auto=format&n=4YB04dlilhUzJTlK&q=85&s=285a63238f0e5eadb3690aee4a3919b8" alt="Dataset" width="318" height="323" data-path="assets/images/superset-dataset-config.png" />

Press **Create Dataset and Create Chart**. On the next screen you can select your desired chart type. For this tutorial we will go with a simple Bar Chart.

<img src="https://mintcdn.com/firebolt-aggregate-helm-docs-pr-4/4YB04dlilhUzJTlK/assets/images/superset-char-type-select.png?fit=max&auto=format&n=4YB04dlilhUzJTlK&q=85&s=6f08129220ad06ca4d1d521baac6f2f4" alt="Chart type" width="1116" height="680" data-path="assets/images/superset-char-type-select.png" />

In the next screen you can drag and drop your table columns into Metrics and Dimensions, specify filters or sorting orders. Configure your chart according to your data and requirements.

<img src="https://mintcdn.com/firebolt-aggregate-helm-docs-pr-4/4YB04dlilhUzJTlK/assets/images/superset-sample-chart.png?fit=max&auto=format&n=4YB04dlilhUzJTlK&q=85&s=56dcdcce95f0a122990921c14bee1528" alt="Chart" width="2253" height="1200" data-path="assets/images/superset-sample-chart.png" />

Your first chart is ready! You can now save it, add more data to it or change its type. You can also start building a dashboard with different charts telling a story. Learn more about this functionality and more by following the links below.

## Further reading

* [Creating your first Dashboard](https://superset.apache.org/docs/creating-charts-dashboards/creating-your-first-dashboard).
* [Exploring data](https://superset.apache.org/docs/creating-charts-dashboards/exploring-data).
* [Firebolt Core documentation](/firebolt-core) for more information about self-hosted Firebolt.
* [Preset](https://preset.io/) - managed Superset for Firebolt Cloud integration.
