---
last_updated: "2026-10-27T07:56:46.000Z"
id: guides-send-vercel-logdrains-to-tinybird
title: Send Vercel log drains to Tinybird
meta:
    description: Learn how to send Vercel events to Tinybird using webhooks and the Events API.
---

# Send Vercel log drains to Tinybird

[Vercel](https://vercel.com) is a platform for building and deploying web applications. By integrating Vercel with Tinybird, you can analyze your Vercel events in real time and enrich it with other data sources.

Some common use cases for sending Vercel logs to Tinybird include:

1. Analyze logs from your applications.
2. Monitor logs from your applications.
3. Create custom analytical dashboards.
4. Build an alert system based on logging patterns.

Read on to learn how to send logs from Vercel to Tinybird.

## Before you start

Before you connect Vercel to Tinybird, ensure:

* You have a Vercel team on the Pro or Enterprise plan. Vercel Drains aren't available on Hobby.
* You have a Tinybird Workspace.

## Create the Data Source

In your Tinybird project, create a Data Source called `vercel_logs`:

```tinybird {% title="datasources/vercel_logs.datasource" %}
SCHEMA >
  `event_time` DateTime `json:$.tinybirdIngestTime` DEFAULT now(),
  `event_type` String `json:$.type` DEFAULT 'unknown',
  `event` JSON `json:$` DEFAULT '{}'

ENGINE "MergeTree"
ENGINE_PARTITION_KEY "toYYYYMM(event_time)"
ENGINE_SORTING_KEY "event_time"
```

The `event` column stores the full log as JSON. Query nested fields with dot notation, for example `event.proxy.path` or `event.statusCode`. See the [Vercel logs schema](https://vercel.com/docs/drains/reference/logs) for every field.

Deploy the project and copy a Token with append permissions on the `vercel_logs` Data Source.

## Connect Vercel to Tinybird

1. In the Vercel dashboard, go to **Team Settings** > **Drains** and select **Add Drain**.
2. Select **Logs** as the data type.
3. Name the drain and select the projects, log sources and environments to send. Optionally, add sampling rules.
4. Under the destination, select **Custom Endpoint** and set the format to **NDJSON**.
5. Set the endpoint URL to the Events API, with the `name` query parameter matching your Data Source:

```text
{% user("apiHost") %}/v0/events?name=vercel_logs
```

{% snippet title="api-region-reminder" /%}

6. Under **Custom Headers**, add `Authorization: Bearer <your-tinybird-token>`.
7. Select **Create Drain**. Vercel tests the endpoint when you create the drain, and you can select **Test** at any time to send sample logs.

If Vercel asks you to verify ownership of the endpoint with an `x-vercel-verify` value, add `x-vercel-verify=<value>` to the endpoint URL as a second query parameter. The Events API returns the value in the `x-vercel-verify` response header.

Check that logs arrive from the **Log** tab of the `vercel_logs` Data Source in Tinybird Cloud.

## Vercel Logs Explorer template

Use the [Vercel Logs Explorer Template](https://www.tinybird.co/templates/vercel-log-drains) to bootstrap a multi-tenant, user-facing logs explorer for your Vercel account. You can fork it and make it your own. The template uses its own `logs` Data Source with typed columns, so point the drain at `/v0/events?name=logs` when you use it.

## See also

* [Events API](/forward/ingest-data/events-api)
* [Vercel Drains](https://vercel.com/docs/drains/using-drains)
