Raw capture โ€” raw/nubase.md


url: https://github.com/OtterMind/Nubase date_fetched: 2026-07-05 backfilled: true


English ยท ็ฎ€ไฝ“ไธญๆ–‡

Official website: https://nubase.ai

โญ If Nubase is useful to you, please give us a star โ€” every star helps more people discover the project and keeps us motivated. Thank you!

Turn AI-written code into real apps. Nubase is an open-source, AI-native backend and deploy layer that a coding agent drives directly โ€” so a generated app goes live in minutes. Eight capability modules in one self-hostable service: Database, Auth, Storage, Assets, Functions, AI Gateway, Memory, and cron.

An agent can model the data (Database + Auth), deploy backend logic (

Functions), publish the generated frontend to a public CDN (Assets), and schedule recurring work (cron) โ€” all through MCP tools, with no separate hosting account. Supabase-style where it makes sense (Postgres, REST, JWTs, RLS, object storage, a Studio dashboard), plus first-classMemoryand anMCPsurface built for AI coding agents.

From your project folder, run:

npx -y nubase_cli@latest install-skillsThat single command:

Then:

This connects your agent to a Nubase instance (a hosted one, or your own โ€” spin one up in step 2). Point the CLI at any instance with:

npx -y nubase_cli@latest install-skills \ --studio-url https://studio.example.com \ --nubase-url https://api.example.com

The all-in-one Docker image bundles PostgreSQL + Redis + the backend + Studio:

docker run -d --name nubase \
  -p 9999:9999 -p 5432:5432 \
  -v nubase_data:/data \
  <your-namespace>/nubase:latest

First-boot secrets are generated into the

/datavolume; keep the volume to retain your projects. For a real deployment with stable secrets, see Self-host with Docker.

Your agent can now operate Nubase directly through MCP tools โ€” inspect schema, create tables, run SQL, manage auth & storage, deploy edge functions, publish a frontend to the public CDN, schedule cron jobs, and read/write durable memory. Try asking:

"Create a

todostable with RLS, deploy an edge function that returns the open count, publish a one-page UI to Assets that calls it, and remember the deployment."

See Deploy an AI-generated app for the full generate โ†’ live walkthrough.

The single all-in-one image is everything you need to run Nubase on your own box โ€” one line, no compose file, no external services.

Try it (auto-generated secrets, kept in the volume):

docker run -d --name nubase -p 9999:9999 -p 5432:5432 \
  -v nubase_data:/data <your-namespace>/nubase:latest

Production (pin stable secrets so encrypted project credentials survive restarts):

docker run -d --name nubase -p 9999:9999 -p 5432:5432 \
  -v nubase_data:/data \
  -e PGRST_ENCRYPTION_MASTER_KEY="$(openssl rand -base64 32)" \
  -e METADATA_SERVICE_ROLE_KEY="$(openssl rand -base64 48)" \
  <your-namespace>/nubase:latest

Everything else is configured via environment variables โ€” Postgres, Redis, S3/R2 storage, SMTP, OAuth, and LLM providers. See docs/docker-all-in-one.md for the full list and a multi-architecture (amd64 + arm64) note.

Replace

<your-namespace>with the Docker Hub namespace the image is published under.

AI-native applications need more than CRUD. They need user memory, retrieval, auth, storage, database APIs, and project isolation from day one. Without that backend layer, every AI coding session produces another demo that still needs weeks of infrastructure work.

Supabase is excellent, but its open-source self-hosted stack is designed around a single project. Nubase is built for AI teams and self-hosters who want one Studio, one backend service, and many isolated AI projects on their own infrastructure โ€” with three opinionated additions:

Full comparison as a table (including Supabase Cloud)

Area Supabase Cloud Supabase self-hosted Nubase
Multi-project dashboard Yes No (mimics one project) Yes
Project isolation Dedicated instance One local project Dedicated Postgres DB per project
Database API PostgREST PostgREST PostgREST-compatible (Java)
Auth Yes Yes Supabase-style Auth
Storage Yes Yes S3/R2-compatible
AI memory Not a core primitive Not a core primitive Built-in Memory pillar
AI coding backend target General primitives General primitives Memory + REST + MCP + Studio
Deploy a generated app App + separate hosting/Functions/cron Self-managed stack Frontend (Assets) + backend (Functions) + cron, one platform
Edge Functions Yes Available in stack Gateway + executor (local / Cloudflare WfP)
Realtime Yes Available in stack Not yet

Nubase has two database layers:

Requests use a two-token model: apikey identifies the project + role (anon / authenticated / service_role), and Authorization: Bearer <jwt> identifies the end user for RLS and memory ownership. A request filter resolves the project from the apikey, routes JDBC to the correct project database, and sets the request context.

Requirements: Java 17, Maven, Docker, Node.js + pnpm.

# 1. Start Postgres (15 + pgvector)
docker compose -f pg-docker-compose.yml up -d
# 2. Required secrets
export PGRST_ENCRYPTION_MASTER_KEY="$(openssl rand -base64 32)"
export METADATA_SERVICE_ROLE_KEY="replace-with-a-long-random-admin-token"
export OPENAI_API_KEY="sk-..."   # optional, only for LLM-powered Memory
# 3. Backend โ†’ http://localhost:9999
mvn spring-boot:run
# 4. Studio โ†’ http://localhost:3000
cd frontend && pnpm install && pnpm dev:studio

To build the all-in-one image yourself: docker build -f Dockerfile.all-in-one -t nubase:local .

Write and search memory:

curl -X POST http://localhost:9999/mem/v1/memories \
  -H "apikey: $NUBASE_SERVICE_KEY" -H "Content-Type: application/json" \
  -d '{"userId":"user-42","messages":[{"role":"user","content":"I prefer steak over sushi and my dog is named Mochi."}]}'
curl -X POST http://localhost:9999/mem/v1/search \
  -H "apikey: $NUBASE_SERVICE_KEY" -H "Content-Type: application/json" \
  -d '{"userId":"user-42","query":"what food do they like?"}'

Use the REST API (after creating a todos table):

curl "http://localhost:9999/rest/v1/todos?select=*" -H "apikey: $NUBASE_ANON_KEY"
curl -X POST "http://localhost:9999/rest/v1/todos" \
  -H "apikey: $NUBASE_SERVICE_KEY" -H "Content-Type: application/json" \
  -d '{"text":"Ship the first open-source release"}'

Nubase is early-stage but all eight modules (Database, Auth, Storage, Assets, Functions, AI Gateway, Memory, cron) plus Studio and the MCP bridge are in place. Not yet implemented: Realtime and operational extras like backups/PITR, HA, and enterprise SSO/SCIM. Review the admin/management endpoints before exposing a server to the public internet.

A huge thank-you to everyone who has starred Nubase! ๐Ÿ™ See the full list on the stargazers page ยป

Contributions and issues are welcome โ€” see CONTRIBUTING.md and SECURITY.md. This is an early public release, so feedback shapes what comes next. ๐Ÿ™Œ