Coder: Self-Hosted Cloud Dev Environments and AI Agents
What Coder is
Coder is a self-hosted platform for cloud development environments (CDEs) and AI coding agents. Platform teams describe workspaces in Terraform, Coder provisions them on infrastructure the organization already runs (EC2 VMs, Kubernetes Pods, Docker containers and so on), and developers connect from the editor they already use through a secure WireGuard tunnel. Workspaces that sit idle are shut down automatically, which is how the project pitches cost control for cloud compute. The documentation describes it as working with any cloud, IDE, OS, Git provider, and identity provider.
The second half of the product is Coder Agents, a native AI coding agent whose loop runs in the Coder control plane rather than inside the workspace or in a vendor's cloud. Developers hand off coding work through the web UI or a REST API, while model credentials, governance and audit logging stay centralized. The intended audience is fairly clear from the docs: platform and developer-experience teams at organizations that want standardized development environments, want source code to stay on private servers, and now want to run coding agents under the same controls.
How Coder works
A Coder deployment centers on the control plane, started with coder server. Administrators write templates in Terraform that describe the infrastructure for a workspace. Because templates are plain Terraform, a workspace can include more than compute: the docs mention storage buckets, secrets and sidecars as examples of extra resources. The Coder Registry ships ready-made templates for AWS EC2, Azure, Google Cloud, Kubernetes and other providers, so a team does not have to write Terraform from scratch to get going.
When a developer creates a workspace from a template, Coder provisions it and connects it back to the control plane over a WireGuard tunnel. Developers then reach the workspace from VS Code, JetBrains IDEs, Cursor, a web terminal, remote desktop or SSH. Web IDEs such as code-server and Jupyter also work, as do remote-development setups like JetBrains Gateway and VS Code Remote. Workspaces can be ARM or x86-64 and run Windows, Linux or macOS from a single deployment.
For agents, the control plane handles planning, model calls and tool dispatch. The docs put it bluntly: workspaces have “zero AI awareness.” The agent acts inside a workspace, but the LLM API keys never enter it, and every action is tied to an authenticated user identity. Models are pluggable (Anthropic, OpenAI, Google, Bedrock or self-hosted endpoints), and switching between them is described as a configuration change. A separate component, the AI Gateway, centralizes authentication, auditing and cost controls for AI tooling more generally.
The docs are also explicit about scope. Coder is not an infrastructure-as-code platform (Terraform is simply its first provisioner), not a CI/CD system, not an online IDE, not a collaboration or code-review platform, and not a SaaS offering. You host it yourself in a private data center or on a cloud provider.
Key features
- Terraform-defined workspaces: templates describe each environment, from a Docker container to a full VM, and admins enforce approved images, resource limits and security policies through them.
- Automatic shutdown: idle workspaces stop on their own and restart in seconds when needed, which keeps cloud spend tied to actual use.
- Any IDE: access through VS Code and JetBrains extensions, Cursor, web terminals, remote desktop or plain SSH.
- Coder Agents: a self-hosted AI coding agent loop with no LLM credentials in workspaces, centralized model approval, per-user spend limits and audit logging.
- Bring your own model: Anthropic, OpenAI, Google, Bedrock or self-hosted endpoints, including air-gapped deployments with local models.
- Third-party agents in workspaces: Registry modules run agents such as Claude Code, Codex and OpenCode isolated inside Coder workspaces.
- Dev Containers support: build environments from
devcontainer.jsonon Docker, Kubernetes and OpenShift. - Configuration as code: the coderd Terraform provider manages deployment configuration declaratively, and GitHub Actions exist for setting up the CLI and updating templates.
- Identity and access: users and groups are managed through SSO (OIDC) and role-based access control.
- Airgap-friendly extensions: a self-hosted VS Code extension marketplace works in restricted networks alongside code-server.
Getting started with Coder
The README's quickstart uses an install script on Linux and macOS; Windows users grab a binary or installer from GitHub Releases.
curl -fsSL https://coder.com/install.sh | shStart the server, then open http://localhost:3000 to create the first user, create a Docker template and provision a workspace:
coder serverWithout extra flags, Coder uses a built-in database and sets up a *.try.coder.app access URL, which is meant for evaluation only. For production, the README says to add a PostgreSQL database (version 13 or later) and an external access URL:
coder server --postgres-url <url> --access-url <url>The project links to validated reference architectures for sizing, and coder --help lists the full set of flags and environment variables. From there the usual path is to pick a template from the Coder Registry that matches your compute (Docker, Kubernetes or a cloud VM) and adapt it.
Use cases
- Faster onboarding: a new engineer picks a template and has a working environment with dependencies installed, instead of spending days on local setup. The README frames this as onboarding “in seconds instead of days.”
- Keeping source code off laptops: code lives on private servers, so a lost or replaced device means revoking access rather than worrying about what was stored locally.
- Heavy builds on server hardware: compile and test on large VMs while developers use lightweight laptops, Chromebooks or tablets as a portal.
- Governed AI coding agents: platform teams define MCP servers, skills and system prompts centrally so every agent session starts with the same tools and policies, with spend limits and audit logs per user.
- Restricted or air-gapped networks: run the entire stack, including the agent loop and self-hosted models, without any SaaS dependency for orchestration.
- CI-driven agent work: use the REST API or the Coder Agents Chat GitHub Action to start an agent session against an issue or pull request.
How Coder compares
Coder sits in the same broad space as hosted cloud development environment services such as GitHub Codespaces. The main distinction the project draws is that the whole system (control plane, agent loop, model routing and workspace provisioning) runs on infrastructure you control. That buys flexibility in compute, OS and network policy, but it also means you operate it, which a managed service would do for you.
On the agent side, the comparison is with running coding agents directly on developer machines or in vendor-hosted sandboxes. Coder supports both of its own models here: third-party CLI agents like Claude Code or Codex can run inside workspaces via Registry modules, while Coder Agents moves the loop into the control plane so credentials and policy live in one place. Which approach fits depends on whether a team values per-developer freedom of tooling or central governance more.
Compared with rolling your own environments from Terraform, Dev Containers or nix, Coder adds the lifecycle layer on top: provisioning on demand, auto-stop, identity, RBAC and IDE connectivity. It deliberately does not replace those tools; Terraform remains the provisioner.
Things to know before adopting Coder
- AGPL-3.0 license: the platform is licensed under the GNU Affero GPL v3. The AGPL's network clause matters if you modify Coder and offer it to users over a network; review it with your legal team before shipping a modified build. Running an unmodified deployment internally is the common case.
- Open core with a Premium tier: the docs state that all developer productivity features are in the open-source version, while a paid Premium license adds enhanced support, dedicated support and features aimed at large teams.
- Self-hosting is mandatory: there is no fully managed offering. Plan for running the control plane, a PostgreSQL database and the underlying compute.
- Terraform is the template language: you do not need to know Terraform to start, thanks to Registry templates, but customizing environments seriously will involve it.
- Evaluation defaults are not production defaults: the built-in database and
*.try.coder.appURL are for trying it out. - Mature codebase: the repository dates back to late 2021, and the project carries OpenSSF Best Practices and Scorecard badges, which is a reasonable signal for security-conscious adopters.
Project activity
As of October 2026 the coder/coder repository has roughly 16,800 stars. It was created on December 22, 2021, is written primarily in Go, and is licensed under AGPL-3.0. Documentation, install guides and pricing details are on the project homepage at coder.com, with community support through Discord and GitHub Discussions and bug reports through GitHub issues.
Enjoying this project?
Discover more amazing open-source projects on TechLogHub. We curate the best developer tools and projects.
Repository:https://github.com/coder/coder
GitHub - coder/coder: Coder: Self-Hosted Cloud Dev Environments and AI Agents
Coder is a self-hosted platform for cloud development environments and AI coding agents. Workspaces are defined in Terraform and run on your own infrastructure,...
github - coder/coder
Related Projects
Open Code Review: AI Code Review CLI from Alibaba
Alibaba's AI code review CLI: reviews Git diffs with an LLM agent and returns line-level comments.
WeKnora: Tencent's Open-Source RAG and Knowledge Framework
Tencent's self-hostable knowledge framework: RAG Q&A, an agent with sandboxed skills, and an auto-built wiki.
TruffleHog: Find, Verify, and Analyze Leaked Secrets
Open-source scanner that finds leaked credentials across Git, S3, Docker and more, and checks if they are live.

