---
title: Setup
description: Install @alchemy.run/convex, create a Convex team access token, and connect it with a profile or CI environment variables.
---
import PackageManagers from "../../../components/PackageManagers.astro";
export const pkgs = `alchemy@latest @alchemy.run/convex@latest convex effect @effect/platform-bun @effect/platform-node`;
## Prerequisites
- [Node.js](https://nodejs.org) 24.11.1+ or [Bun](https://bun.sh)
- A Convex team. Sign up at [convex.dev](https://www.convex.dev); the free plan is enough to start.
## Create a project
## Install
`convex` is Convex's own package. `Convex.Functions` pushes with its CLI, and your functions import it.
## Add the provider
Add `Convex.providers()` to your Stack:
```typescript title="alchemy.run.ts"
import * as Convex from "@alchemy.run/convex";
import * as Alchemy from "alchemy";
import * as Effect from "effect/Effect";
export default Alchemy.Stack(
"MyApp",
{ providers: Convex.providers(), state: Alchemy.localState() },
Effect.gen(function* () {
yield* Convex.Project("App");
}),
);
```
## Connect a profile
Create a team access token in your team's settings. A token belongs to the person who created it, so use a service account for anything shared. Then store it in your `default` [profile](/environments/profiles):
Paste the token when asked, and leave the team ID blank: Alchemy reads it from the token.
See [Teams and tokens](/convex/teams-and-tokens).
## Use environment variables in CI
Set `CONVEX_ACCESS_TOKEN`, and Alchemy uses it instead of your profile:
`CONVEX_TEAM_ID` is optional, and only checks that the token is for the team you expect. See [CI](/environments/ci).
## Mix with another cloud
Merge the providers:
```typescript
providers: Layer.mergeAll(Cloudflare.providers(), Convex.providers()),
```
## Local development
Convex has no emulator in Alchemy, so `alchemy dev` creates and uses real Convex deployments. Each stage gets its own.
## Plans
Custom domains, log streams and data sync need the Convex Professional plan. Audit logs need a plan that keeps them.