Like Supabase,
but code your
AI can read.

Add a typebase/ folder to your repo: database, server functions, auth, and file storage, all in TypeScript. No dashboard settings, no SQL policies. Every rule is code your AI can see.

npx typebase-io-cli init
One function. Both sides.01 → 02

SERVER · typebase/actions/queries/todos.ts

import { action } from '../../_generated/server';export const getMany = action  .handler(async ({ db }) => {    return db.query.todos.findMany();  });
Types travel with the call. Over HTTP.

FRONTEND · src/app/page.tsx

import { client } from '@/lib/typebase/client';export default async function Page() {  const todos = await client.queries.todos.getMany();  // ^? { id: number; value: string; completed: boolean }[]  return todos.map((t) => (    <li key={t.id}>{t.value}</li>  ));}

Keep the frontend you like.

Pick your framework. There’s a guide.

tl;dr: three files, database to UI

typebase/db/schema.tsTS
import { p } from 'typebase-io/db';export const todos = p.pgTable('todos', {  id: p.integer().primaryKey().generatedAlwaysAsIdentity(),  value: p.text().notNull(),  completed: p.boolean().notNull().default(false),});

Register this table in db/relations.ts to query it in your actions.

Follow the types

Give your data a home.

Define your Postgres tables in TypeScript. Typebase gives your server functions a typed database client.

Explore the database guide

Your agent’s
kind of backend.

Your schema, auth, and server functions live in the repo your agent is already working in. It can follow the code from a database table all the way to your frontend.

  • Familiar tools. TypeScript, Drizzle, better-auth, and oRPC, with their own docs for your agent to read.
  • Useful feedback. The type checker catches mismatches as your agent makes changes.
  • A skill for the specifics. File conventions, commands, and setup instructions, ready for your agent to read.
See what the skill teaches your agent
Your next conversationReady to paste
Add a Typebase backend to this project.

Read the project first. Install the Typebase skill with:
npx skills add typebase-io/monorepo
Read the skill before writing code.

Ask what I’m building, what data I need, and whether users should sign in. Then install Typebase, scaffold the backend, and connect it to my existing frontend. Follow the skill and keep the project’s conventions.

For private data, verify the session and check ownership in server actions. Validate inputs and accept only the fields each action needs. Run the project’s type checks and test the permission checks.

Summarize your changes and stop before deploying. I’ll handle the first deployment and provider login.

Paste into Claude Code, Cursor, Codex, or your preferred coding agent.

RLS policies.
Plain TypeScript checks.

Alice should see Alice’s todos. Signed in is not the same as owner, and that gap is easy to miss in a policy, because nothing in your editor is checking it. Here is the same rule, written twice.

Other providers

app.supabase.com / auth / policiesSQL policy
Authentication › Policies › public.todos
NameCmdUsing expression
Enable read for allpublicSELECTtrue
Users can update todosauthenticatedUPDATEauth.role() = 'authenticated'
Owners can deleteauthenticatedDELETEuser_id = auth.uid()

Policy 2 passes for anyone signed in. Bob can update Alice’s row, in every column, plus any column you add later. No type checker reads this.

Typebase.

typebase/actions/queries/todos.tsTypeScript
The same rule, next to the query it protects
import { authedAction } from '../custom-actions';export const getMine = authedAction  .handler(async ({ db, user }) => {    return db.query.todos.findMany({      where: { userId: user.id },    });  });

authedAction checks the session, and the highlighted line narrows the rows to that user. Change the shape and the type checker tells you.

See authorization in code

The DX of Convex.
The openness of Supabase.

A dashboard setting never shows up in a pull request. There’s no diff to review and no commit to revert, so your repo and your backend drift apart. A toggle someone flips on Tuesday can break production without a line of code changing. Your agent can’t see it either; it only reads the repo. In Typebase your schema, auth, and permission checks are files, reviewed like the rest of your app.

Typebase, Supabase, and Convex: backend logic, database, type safety, realtime, auth, storage, hosting, and application dependencies
Your choicesTypebaseSupabaseConvex
Backend logicTypeScript actionsSQL functions and Edge FunctionsQueries, mutations, and actions
DatabasePostgresPostgresProprietary
Type safetyEnd-to-end, always in syncGenerated, can driftEnd to end
RealtimeStreaming actions over SSERealtime subscriptionsReactive queries
Authbetter-auth, configured in one fileBuilt in, configured in the dashboardThird-party providers
StorageVercel Blob or Cloudflare R2, declared in one fileBuilt in, managed in the dashboardBuilt in
HostingYour providers, or a generated serverSupabase Cloud or self-hostedConvex Cloud or self-hosted
Read the full comparison

Explore Typebase. This is the whole backend.

Each file has one job. db/ defines your tables, anything you export from actions/ becomes an endpoint your frontend can call, and auth.ts gives those functions a session to check. One command regenerates the types and deploys the folder as a server.

  • typebase/
  • actions/
  • mutations/
  • queries/
  • db/
typebase/actions/queries/todos.tsread
import { z } from 'zod';import { action } from '../../_generated/server';export const getByStatus = action  .input(z.object({ completed: z.boolean() }))  .handler(async ({ db, input }) => {    return db.query.todos.findMany({      where: { completed: input.completed },    });  });

Validate the input, filter the read, and the return type reaches your frontend.

Real backend.
Imaginary fan club.

None of these people exist. Their taste in backend tooling is excellent tho.

I deleted 40,000 lines of REST plumbing last quarter. My tech lead cried. I think they were happy tears. I have stopped asking.
Mariel VonnegutPrincipal Eng, AI unicorn you’ve heard of
Before Typebase I had three acronyms in my pipeline: REST, gRPC, and WHY. Now I have one: fn(). I have never been happier and my Oura ring agrees.
Dave DaveSenior Fullstack, maybe
I’ve told four separate therapists about Typebase. Two stopped taking me as a client. The other two are now shipping an app with it.
Clementine RyuEngineer, between therapists
My co-founder asked where the auth lives. I said “a file called auth.ts.” He hasn’t spoken to me since. I assume he’s impressed.
Tomás LindbergIndie hacker, possibly single
We replaced 14 microservices with one folder. The DevOps team threw me a party. The party was a meeting. The meeting was about layoffs.
AnonymousFor obvious reasons
10/10 would make my backend a folder again.
Hannah PollardSenior Folder Engineer, self-appointed

* The people are made up. The code above isn’t.

Fair questions,
straight answers.

Watch Typebase in 100 seconds

Yes. Install Typebase in your existing JavaScript or TypeScript project. Your frontend stays where it is; the backend goes in a typebase/ folder. Start with the getting started guide.

Typebase is a library and CLI. Your server runs in your own hosting account, and the database and files are yours too. The CLI deploys to Vercel, Cloudflare Workers, or Deno Deploy with a Neon database, and keeps files in Vercel Blob or Cloudflare R2. You can also generate a server to host yourself.

Typebase is free and open source under the MIT license. You pay your hosting and database providers for their usage. Typebase doesn’t add a platform fee.

Typebase keeps everything in one place. Your tables, your server functions, and your auth are files in the repo you already have, not settings spread across a dashboard and a handful of separate services. There is no new paradigm to learn either: where Convex asks you to take on its document model, its query API, and its reactive defaults, Typebase is TypeScript over ordinary Postgres, with Drizzle and better-auth doing the work you already know them for. The goes row by row.

Yes. The start command builds your server and restarts it as you edit. If you use a database, connect your own local Postgres or a dev database. Follow the local development guide.

Good idea.
Now give it a backend.

Start with one function. Build the rest as you go.

Get started
npm i typebase-io && npm i -D typebase-io-cli