---
title: sproutboat.jsonc
description: "The full configuration file: name, entry point, bindings, vars, secrets, triggers, and assets."
---

`sproutboat.jsonc` is JSONC: comments and trailing commas are allowed. Unknown fields are rejected.

:::warning
Every binding name is `UPPER_SNAKE_CASE` and unique across the whole file: a var and a binding cannot share a name.
:::

## Full shape

```jsonc
{
  "$schema": "https://sproutboat.com/schema.json",
  "name": "hello",                      // lowercase slug, up to 32 characters; part of your hostname
  "main": "src/index.js",               // entry point under src/; .ts works too
  "compatibility_date": "2026-09-28",   // YYYY-MM-DD; picks the handler signature

  "vars": { "APP_URL": "https://hello.example.com" },   // baked in, read as env.APP_URL

  "kv_namespaces": ["SESSIONS"],        // bare name, or { "binding": "SESSIONS", "id": "kv_..." }
  "d1_databases": ["DB"],
  "r2_buckets": ["MEDIA"],
  "queues": ["JOBS"],
  "analytics_engine_datasets": ["EVENTS"],   // bare name only; no id

  "secrets": ["STRIPE_KEY"],            // value set with `sproutboat secrets put`, read as env.STRIPE_KEY

  "services": [{ "binding": "PEER", "service": "quote-service" }],   // another of your projects
  "durable_objects": { "COUNTER": "Counter" },   // binding -> class name in the entry file
  "version_metadata": "VERSION",                 // env.VERSION.id, .tag, .timestamp

  "ratelimiters": [                              // env.API.limit({ key }) -> { success, resetAt }
    { "binding": "API", "limit": 100, "period": 60 }   // 100 per 60s, per key
  ],

  "triggers": { "crons": ["0 * * * *"] },        // 5-field UTC cron

  "assets": {
    "directory": "public",                       // files published with the artifact
    "binding": "ASSETS",                          // env.ASSETS.fetch(request)
    "not_found_handling": "single-page-application",
    "run_sprout_first": ["/api/*"]                // paths the handler sees before the asset server
  }
}
```

## Field reference

| Field | Purpose | Details |
| --- | --- | --- |
| `name` | Project slug | Lowercase letters, digits and hyphens, up to 32 characters. The project is served at `<name>.<username>.<platform-domain>`. |
| `main` | Entry point | A `.js` or `.ts` file under `src/`. |
| `compatibility_date` | Runtime pin | `YYYY-MM-DD`. From `2026-09-28` the handler receives `(request, env, ctx)`; see [The handler](/docs/concepts/handler). |
| `vars` | Build-time constants | See [Vars](/docs/bindings/vars). |
| `kv_namespaces` | KV bindings | See [KV](/docs/bindings/kv). |
| `d1_databases` | D1 bindings | See [D1-compatible SQLite](/docs/bindings/d1). |
| `r2_buckets` | R2 bindings | See [R2-compatible object storage](/docs/bindings/r2). |
| `queues` | Queue bindings | See [Queues](/docs/bindings/queues). |
| `analytics_engine_datasets` | Analytics Engine bindings | See [Analytics Engine](/docs/bindings/analytics-engine). |
| `secrets` | Secret bindings | See [Secrets](/docs/bindings/secrets). |
| `services` | Service bindings | See [Service bindings](/docs/bindings/service-bindings). |
| `durable_objects` | Durable Object bindings | See [Durable Objects](/docs/bindings/durable-objects). |
| `version_metadata` | Version metadata binding | See [Version metadata](/docs/bindings/version-metadata). |
| `ratelimiters` | Rate limiter bindings | See [Rate limiting](/docs/bindings/rate-limiting). |
| `triggers.crons` | Cron schedule | See [Cron](/docs/bindings/cron). |
| `assets` | Static asset serving | See [Static assets](/docs/bindings/static-assets). |
