{
  "slug": "netlify-db-connect-reads-netlify-db-url-b154fb37a257",
  "title": "netlify db connect reads NETLIFY_DB_URL",
  "tools": [
    "netlify"
  ],
  "tags": [
    "agent"
  ],
  "introduced_at": "2026-04-09T15:17:59.000Z",
  "announced_at": "2026-04-09T15:17:59.000Z",
  "effective_at": null,
  "date_basis": "source-publication",
  "status": "unknown",
  "how": {
    "incantation": "When `NETLIFY_DB_URL` is present, run `netlify db connect` to connect using that connection string. The v24.11.0 source checks this variable before its stored local connection string.",
    "gotchas": [
      "Version: 24.11.0",
      "NETLIFY_DB_URL: When set, supplies the connection string used by the connect command.",
      "The environment variable must be present.",
      "Docs conflict: Current Netlify CLI docs use `netlify database connect` and specify Node.js 20.12.2+ and Netlify CLI 26.0.0+; these docs describe a later version than v24.11.0: https://docs.netlify.com/build/data-and-storage/netlify-database/cli/"
    ]
  },
  "why_it_matters": "Connect an agent runner to the database for its corresponding deploy preview.",
  "sources": [
    "https://github.com/netlify/cli/releases/tag/v24.11.0",
    "https://github.com/netlify/cli/pull/8142",
    "https://github.com/netlify/cli/blob/v24.11.0/src/commands/database/db-connection.ts"
  ],
  "rank": 0.92026,
  "judge": {
    "publish": true,
    "judge_model": "codex-cli/gpt-6-luna+typesafe/jev-1.13.0",
    "prompt_version": "extract-v7+enrich-v2+judge-v2x3+jev-publish-v1"
  },
  "review_state": "approved",
  "provenance": {
    "run_id": "wave2a-20261017",
    "verdict_id": "wave2a-20261017:wave2a-20261017-8e1d91c6565af909-0:gate",
    "evidence_hash": "82d51ecb0ae15fc529018bbbc46a743d29c3747cce558e9d4ff54a78f9ea972d"
  },
  "review": {
    "draft_hash": "17853e92aefcaa371b79b6c41ef8190ae54a3950f6eceecad89120b9b3aee360",
    "reviewer": "publication-gate",
    "reviewed_at": "2026-10-07T00:00:00.000Z",
    "decision": "wave2a-20261017:gate",
    "reason": "2 of 3 judge runs approved with p_yes >= 0.9 (mean 0.92 >= 0.9; 2 needed) and Jev gave 0.72 (>= 0.6 needed)."
  }
}
