[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-73778":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":15,"contributorsCount":16,"subscribersCount":16,"size":16,"stars1d":16,"stars7d":16,"stars30d":17,"stars90d":16,"forks30d":16,"starsTrendScore":16,"compositeScore":18,"rankGlobal":10,"rankLanguage":10,"license":19,"archived":20,"fork":20,"defaultBranch":21,"hasWiki":20,"hasPages":20,"topics":22,"createdAt":10,"pushedAt":10,"updatedAt":28,"readmeContent":29,"aiSummary":30,"trendingCount":16,"starSnapshotCount":16,"syncStatus":31,"lastSyncTime":32,"discoverSource":33},73778,"database-build","supabase-community\u002Fdatabase-build","supabase-community","In-browser Postgres sandbox with AI assistance (formerly postgres.new)","https:\u002F\u002Fdatabase.build",null,"TypeScript",2949,274,28,35,0,5,59.82,"Apache License 2.0",false,"main",[23,24,25,26,27],"ai","browser","llm","pglite","postgres","2026-06-12 04:01:11","# database.build ([formerly postgres.new](#why-rename-postgresnew))\n\nIn-browser Postgres sandbox with AI assistance.\n\n![github-repo-hero](https:\u002F\u002Fgithub.com\u002Fuser-attachments\u002Fassets\u002F1ace0688-dfa7-4ddb-86bc-c976fa5b2f42)\n\nWith [database.build](https:\u002F\u002Fdatabase.build), you can instantly spin up an unlimited number of Postgres databases that run directly in your browser (and soon, deploy them to S3).\n\nEach database is paired with a large language model (LLM) which opens the door to some interesting use cases:\n\n- Drag-and-drop CSV import (generate table on the fly)\n- Generate and export reports\n- Generate charts\n- Build database diagrams\n\n## How it works\n\nAll queries in database.build run directly in your browser. There’s no remote Postgres container or WebSocket proxy.\n\nHow is this possible? [PGlite](https:\u002F\u002Fpglite.dev\u002F), a WASM version of Postgres that can run directly in your browser. Every database that you create spins up a new instance of PGlite that exposes a fully-functional Postgres database. Data is stored in IndexedDB so that changes persist after refresh.\n\n## Monorepo\n\nThis is a monorepo split into the following projects:\n\n- [Web](.\u002Fapps\u002Fweb\u002F): The primary web app built with Next.js\n- [Browser proxy](.\u002Fapps\u002Fbrowser-proxy\u002F): Proxies Postgres TCP connections back to the browser using [pg-gateway](https:\u002F\u002Fgithub.com\u002Fsupabase-community\u002Fpg-gateway) and Web Sockets\n- [Deploy worker](.\u002Fapps\u002Fdeploy-worker\u002F): Deploys in-browser databases to database platforms (currently Supabase is supported)\n\n### Setup\n\nFrom the monorepo root:\n\n1. Install dependencies\n\n   ```shell\n   npm i\n   ```\n\n2. Start local Supabase stack:\n   ```shell\n   npx supabase start\n   ```\n3. Store local Supabase URL\u002Fanon key in `.\u002Fapps\u002Fweb\u002F.env.local`:\n   ```shell\n   npx supabase status -o env \\\n     --override-name api.url=NEXT_PUBLIC_SUPABASE_URL \\\n     --override-name auth.anon_key=NEXT_PUBLIC_SUPABASE_ANON_KEY |\n       grep NEXT_PUBLIC >> .\u002Fapps\u002Fweb\u002F.env.local\n   ```\n4. Create an [OpenAI API key](https:\u002F\u002Fplatform.openai.com\u002Fapi-keys) and save to `.\u002Fapps\u002Fweb\u002F.env.local`:\n   ```shell\n   echo 'OPENAI_API_KEY=\"\u003Copenai-api-key>\"' >> .\u002Fapps\u002Fweb\u002F.env.local\n   ```\n5. Store local KV (Redis) vars. Use these exact values:\n\n   ```shell\n   echo 'KV_REST_API_URL=\"http:\u002F\u002Flocalhost:8080\"' >> .\u002Fapps\u002Fweb\u002F.env.local\n   echo 'KV_REST_API_TOKEN=\"local_token\"' >> .\u002Fapps\u002Fweb\u002F.env.local\n   ```\n\n6. Start local Redis containers (used for rate limiting). Serves an API on port 8080:\n\n   ```shell\n   docker compose -f .\u002Fapps\u002Fweb\u002Fdocker-compose.yml up -d\n   ```\n\n7. Fill in the remaining variables for each app as seen in:\n\n   - `.\u002Fapps\u002Fweb\u002F.env.example`\n   - `.\u002Fapps\u002Fbrowser-proxy\u002F.env.example`\n   - `.\u002Fapps\u002Fdeploy-worker\u002F.env.example`\n\n### Development\n\nFrom the monorepo root:\n\n```shell\nnpm run dev\n```\n\n_**Important:** This command uses `turbo` under the hood which understands the relationship between dependencies in the monorepo and automatically builds them accordingly (ie. `.\u002Fpackages\u002F*`). If you by-pass `turbo`, you will have to manually build each `.\u002Fpackages\u002F*` before each `.\u002Fapp\u002F*` can use them._\n\n## Why rename postgres.new?\n\nThis project is not an official Postgres project and we don’t want to mislead anyone! We’re renaming to database.build because, well, that’s what this does. This will still be 100% Postgres-focused, just with a different URL.\n\n## Video\n\n[![image](https:\u002F\u002Fgithub.com\u002Fuser-attachments\u002Fassets\u002F9da04785-d813-4e9c-a400-4e00c63381a1)](https:\u002F\u002Fyoutu.be\u002FooWaPVvljlU)\n\n## License\n\nApache 2.0\n","database.build 是一个基于浏览器的Postgres数据库沙箱，并配有AI助手。该项目允许用户在浏览器中即时创建无限数量的Postgres数据库，并且每个数据库都与大型语言模型（LLM）配对，支持拖放CSV导入、生成报告、图表绘制及构建数据库图等高级功能。技术上，它利用了PGlite（一种可在浏览器内运行的WebAssembly版本Postgres），确保所有操作都在本地执行而无需远程服务器，数据通过IndexedDB持久化存储。非常适合需要快速测试SQL查询、进行数据分析或学习Postgres的新手和专业人士使用。",2,"2026-06-11 03:47:20","high_star"]