MCPcopy
hub / github.com/get-convex/convex-backend

github.com/get-convex/convex-backend @precompiled-2026-06-09-b6aaa1a sqlite

repository ↗ · DeepWiki ↗ · release precompiled-2026-06-09-b6aaa1a ↗
5,766 symbols 24,074 edges 2,846 files 348 documented · 6%
README

Convex logo

Convex is the open-source reactive database designed to make life easy for web app developers, whether human or LLM. Fetch data and perform business logic with strong consistency by writing pure TypeScript.

Convex provides a database, a place to write your server functions, and client libraries. It makes it easy to build and scale dynamic live-updating apps. Read the docs to learn more.

Development of the Convex backend is led by the Convex team. We welcome small bug fixes and love receiving feedback. We keep this repository synced with any internal development work within a handful of days. Convex is a well tested piece of software, with several well designed test frameworks including randomized testing. Those tests are not provided as part of the open source offering.

Getting Started

Visit our documentation to learn more about Convex and follow our getting started guides.

The easiest way to build with Convex is through our cloud platform, which includes a generous free tier and lets you focus on building your application without worrying about infrastructure. Many small applications and side-projects can operate entirely on the free tier with zero cost and zero maintenance.

Self Hosting

The self-hosted product includes most features of the cloud product, including the dashboard and CLI. Self-hosted Convex works well with a variety of tools including Neon, Fly.io, Vercel, Netlify, RDS, Sqlite, Postgres, and more.

You can either use Docker (recommended) or a prebuilt binary to self host Convex. Check out our self-hosting guide for detailed instructions. Community support for self-hosting is available in the #self-hosted channel on Discord.

Community & Support

  • Join our Discord community for help and discussions.
  • Report issues when building and using the open source Convex backend through GitHub Issues
  • By submitting pull requests, you confirm that Convex can use, modify, copy, and redistribute the contribution, under the terms of its choice.

Building from source

See BUILD.md.

Disclaimers

  • If you choose to self-host, we recommend following the self-hosting guide. If you are instead building from source, make sure to change your instance secret and admin key from the defaults in the repo.
  • Convex is battle tested most thoroughly on Linux and Mac. On Windows, it has less experience. If you run into issues, please message us on Discord in the #self-hosted channel.
  • Convex self-hosted builds contain a beacon to help Convex improve the product. The information is minimal and anonymous and helpful to Convex, but if you really want to disable it, you can set the --disable-beacon flag on the backend binary. The beacon's messages print in the log and only include
  • A random identifier for your deployment (not used elsewhere)
  • Migration version of your database
  • Git rev of the backend
  • Uptime of the backend

Repository layout

  • crates/ contains Rust code

  • Main binary

    • local_backend/ is an application server on top of the Runtime. This is the serving edge for the Convex cloud.
  • npm-packages/ contains both our public and internal TypeScript packages.

  • Internal packages
    • udf-runtime/ sets up the user-defined functions JS environment for queries and mutations
    • system-udfs/ contains functions used by the Convex system e.g. the CLI

Extension points exported contracts — how you extend this code

IScenario (Interface)
(no doc) [7 implementers]
npm-packages/scenario-runner/scenario.ts
Query (Interface)
(no doc) [6 implementers]
npm-packages/convex/src/server/query.ts
LocalDbReader (Interface)
(no doc) [6 implementers]
npm-packages/local-store/react/localDb.ts
LDProps (Interface)
* The possible props the wrapped component can receive from the `LDConsumer` HOC.
npm-packages/dashboard/src/providers/LaunchDarklyProviders.tsx
Syscalls (Interface)
(no doc) [1 implementers]
npm-packages/node-executor/src/syscalls.ts
Context (Interface)
(no doc) [1 implementers]
npm-packages/@convex-dev/codemod/src/context.ts
UseFlexLayoutInstanceProps (Interface)
(no doc)
npm-packages/dashboard-common/src/react-table-config.d.ts
UseFlexLayoutInstanceProps (Interface)
(no doc)
npm-packages/dashboard-self-hosted/src/react-table-config.d.ts

Core symbols most depended-on inside this repo

log
called by 437
npm-packages/convex/src/browser/logging.ts
object
called by 395
npm-packages/dashboard-common/src/elements/ObjectEditor/ast/ast.ts
query
called by 348
npm-packages/local-store/react/localDb.ts
crash
called by 314
npm-packages/@convex-dev/codemod/src/context.ts
get
called by 305
npm-packages/convex/src/cli/lib/env.ts
mutation
called by 294
npm-packages/convex/src/react/client.ts
filter
called by 273
npm-packages/local-store/react/localDb.ts
query
called by 249
npm-packages/system-udfs/convex/_system/secretSystemTables.ts

Shape

Function 4,045
Method 1,170
Class 290
Interface 261

Languages

TypeScript99%
Python1%

Modules by API surface

npm-packages/convex/src/bundler/fs.ts68 symbols
npm-packages/local-store/shared/pagination.ts67 symbols
npm-packages/udf-runtime/src/02_event.ts66 symbols
npm-packages/convex/src/values/validators.ts65 symbols
npm-packages/convex/src/cli/lib/utils/utils.ts59 symbols
npm-packages/private-demos/middleware/convex/lib/rowLevelSecurity.ts55 symbols
npm-packages/convex/src/react/client.ts47 symbols
npm-packages/udf-runtime/src/27_performance.ts45 symbols
npm-packages/udf-runtime/src/23_request.ts42 symbols
npm-packages/udf-runtime/src/00_url.ts41 symbols
npm-packages/udf-runtime/src/09_file.ts39 symbols
npm-packages/convex/src/browser/sync/client.ts38 symbols

Dependencies from manifests, versioned

@auth0/auth0-react2.15.1 · 1×
@aws-sdk/client-s33.171.0 · 1×
@babel/code-frame7.27.1 · 1×
@babel/core7.27.1 · 1×
@babel/parser7.27.1 · 1×
@babel/preset-env7.27.1 · 1×
@babel/types7.27.1 · 1×
@clerk/backend3.2.14 · 1×
@clerk/nextjs7.2.1 · 1×
@clerk/react6.4.3 · 1×
@clerk/tanstack-react-start1.1.4 · 1×
@clerk/testing1.5.1 · 1×

Datastores touched

(mysql)Database · 1 repos
dev_dbDatabase · 1 repos
preview_dbDatabase · 1 repos
prod_dbDatabase · 1 repos

For agents

$ claude mcp add convex-backend \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact