How to Use Coder: The Beginner's Guide (First Server, the Template Rule, First Workspace, and the Autostop Lesson)

CodexFuse Team · 2026-11-01T05:14:56.380Z · 16 min read

Coder is the self-hosted remote development platform from coder.com: define a workspace once as a Terraform template, then every developer spins up an identical environment in seconds. This beginner's guide covers the install, the first admin user, the template rule, the first Docker template and workspace, IDE connection, port-forwarding, and the autostop lesson.

Learning how to use Coder is the fastest way to move your development environment off your laptop and onto infrastructure you control. This guide is about Coder — the self-hosted remote development platform from coder.com — not the Raspberry Pi "Coder" project, the VEX robot "Coder", or an AI coding assistant with "coder" in its name. Coder runs your dev environments as code: you define a workspace once as a template, then every developer on your team spins up an identical environment in seconds. This coder tutorial for beginners runs the complete first arc in one page: the install, the first admin user, the template rule (workspaces are Terraform code — no click-ops), your first Docker template, your first workspace, connecting from VS Code and SSH, the autostop lesson that decides your bill, and port-forwarding for previews. If containers are new to you, our Docker beginner guide covers the runtime your first template will use — this guide is the environment layer on top of it.

What Is Coder?

Coder is a self-hosted platform for remote development environments — the company calls them "cloud development environments". Instead of every developer installing toolchains on their own laptop and debugging "works on my machine" problems, Coder provisions real environments (Docker containers, VMs, or Kubernetes pods) on your own servers or cloud accounts, and developers connect to them from any IDE. The code, the compute, and the data all stay on infrastructure you own.

The load-bearing idea is the template rule, and it needs three lines of Terraform context. Terraform is HashiCorp's open-source infrastructure-as-code language — you write what you want, and it builds it. Coder templates are Terraform blueprints for developer environments: they describe the infrastructure for each workspace, from EC2 VMs and Kubernetes pods to Docker containers. And the docs say it plainly: "Coder is not an IaC platform. Terraform is the first IaC provisioner in Coder." Beginners never have to write this Terraform — starter templates and the template builder do it for you — but the rule is that every workspace comes from a template, never from clicking around a dashboard.

A template is the recipe; a workspace is the running environment. The Coder server essentially runs a terraform apply every time a workspace is created, started, or stopped. As of this writing the current release is v2.37.9, published October 30, 2026.

How Do I Use Coder for the First Time?

Using Coder for the first time means running five moves in order: install the Coder server, create your admin account, pick a starter template, launch your first workspace, and connect your IDE. Here is the complete beginner arc in ten steps.

  1. Install the Coder CLI with the official installer: curl -fsSL https://coder.com/install.sh | sh.
  2. Start the server with coder server and open the dashboard URL it prints (locally http://localhost:3000, or the try.coder.app tunnel URL on a remote machine).
  3. Create your admin account — the first user you create is automatically the admin.
  4. Open the template builder and select the Docker base template — no Terraform writing required.
  5. Name your template my-docker-template and add modules like code-server if you want browser-based VS Code.
  6. Create the template — Coder composes and validates the Terraform server-side.
  7. Create a workspace from the template; it starts in about 10–15 seconds.
  8. Connect from VS Code Desktop using the Coder extension, or open the workspace in your terminal.
  9. Clone your repo into the workspace and start working — your laptop stays a thin client.
  10. Set an autostop timer on the template before you forget, so idle workspaces stop instead of burning compute.

What Do You Need Before You Install Coder?

You need a machine with 2+ CPU cores and 4 GB+ RAM, a Docker-compatible runtime for the starter templates, a terminal, and about ten minutes — those are the official quickstart prerequisites from coder.com. The Docker requirement matters because the beginner path runs workspaces as Docker containers; the server itself doesn't care where it lives. Most beginners run the server on a cheap VPS — if server sizing is new to you, our what is VPS hosting guide explains the machine you're renting and why the specs matter.

One important warning about networking: on a remote machine, the quickstart prints a tunnel URL on try.coder.app so you can reach the dashboard for testing. That tunnel is for testing, not production exposure — for real use you put Coder behind your own domain with HTTPS, the same way you would any other service you host.

How Do You Install Coder?

You install Coder with the official install script, which downloads the single Coder binary and drops it on your PATH. The current install command, verified from the install script itself, is:

curl -fsSL https://coder.com/install.sh | sh
# then
coder server

Running coder server starts the Coder deployment on your machine. Watch the server logs: locally the dashboard appears at http://localhost:3000, and on a remote machine the logs print a try.coder.app tunnel URL you open in your browser. The installer also supports the usual package routes — Homebrew, apt, dnf, and winget — but the script above is the one the docs bless, and it's the one you should treat as current.

How Do You Create Your First Admin User?

Your first admin user is created in the dashboard you just opened, and the first account you create is automatically the administrator — there is no separate "admin setup" ritual to learn. This is the account that owns templates, manages users, and configures the deployment, so use a real email address and a strong password. Coder also supports GitHub SSO for sign-in, which teams usually switch to once more than one person is using the deployment.

After signing in, the dashboard is mostly empty — and that is the point. Coder has no "default workspace" because workspaces only exist inside templates, and you haven't made one yet. The next section is the rule that makes the whole platform make sense.

The Template Rule: Why You Don't Click-Ops Your Environments

The template rule is the single rule that decides whether Coder saves you time or creates a mess: every workspace is created from a template, and templates are Terraform code. You never hand-build an environment in the dashboard and hope someone reproduces it later. The template is the recipe, the workspace is the dish, and the recipe is versioned, reviewable, and reusable.

Beginners should not start by writing Terraform. Coder ships starter templates and a template builder that composes the Terraform for you and validates it server-side. The beginner move is the Docker base template: select it in the builder, name it my-docker-template, optionally add modules like code-server for browser-based VS Code, and create the template. Under the hood, creating the template registers Terraform that provisions a Docker container with a developer's home directory, and every workspace you launch from it runs terraform apply against that same recipe. When you later outgrow the builder, the "write a template from scratch" tutorial shows you the raw Terraform — the mental model doesn't change, only the amount of code you touch.

How Do You Launch Your First Workspace?

You launch your first workspace by picking your new template in the dashboard and clicking Create Workspace — Coder provisions it in about 10–15 seconds and drops you into a running container with your code tooling. Name the workspace something you will recognize in a list, like my-first-workspace, because you will accumulate more of them and "workspace-3" tells you nothing in three months. If you added the code-server module to the template, the workspace opens browser-based VS Code immediately, which is the fastest way to confirm everything works before you wire up a desktop IDE.

Inside the workspace you are on a real Linux machine: clone a repo, run the test suite, install project dependencies. Notice what changed for your laptop — it is now a thin client showing you a remote machine. Nothing builds locally, nothing eats your battery, and a teammate who creates a workspace from the same template gets the byte-identical environment.

How Do You Connect Your IDE to a Coder Workspace?

You connect your IDE to a Coder workspace through SSH, and Coder gives you several doors into the same machine. If VS Code itself is new to you, our VS Code beginner guide covers the editor side — the Coder side is just the connection. Here are the five ways in, in the order most beginners try them:

Connection methodWhat it doesBest for
coder ssh my-workspaceSSH straight into the workspace from the Coder CLIQuick terminal sessions and scripting
VS Code Desktop + Coder extensionOpens the workspace as a remote VS Code windowDaily development in VS Code
code-server (browser)VS Code in a browser tab, no installChromebooks and borrowed machines
JetBrains GatewayIntelliJ, PyCharm, GoLand, Rider, CLion, RubyMine, WebStorm, or Fleet against the workspaceJetBrains shops
Coder DesktopNative app with a VPN tunnel and automatic port forwardingAlways-on, appliance-like access

The CLI pair worth memorizing is coder ssh and coder config-ssh. The first opens a shell in the workspace directly; the second writes SSH config entries so you can connect with plain ssh coder.<workspace_name> from any tool that speaks SSH. Coder generates SSH key pairs per user, so you don't hand-manage keys the way old-school shared servers demanded. Cursor, Windsurf (now Devin Desktop), and Antigravity also work through the Coder extension, which matters if your team has already picked an AI-assisted editor.

How Does Port-Forwarding Work in Coder?

Port-forwarding in Coder answers the question every web developer asks five minutes into a remote environment: "my app is running — how do I see it?" Coder answers it two ways. In the dashboard, the workspace shows a "listening ports" window where you can open the dev server or preview your app is serving — no tunnel commands needed. From the terminal, the CLI does it explicitly:

# Forward the workspace's port 8080 to your laptop
coder port-forward my-workspace --tcp 8080

Port-forwarding through the CLI also lets you share ports with other users, which is how you demo a branch's preview to a teammate without deploying anything. Coder Desktop adds automatic port forwarding on top, so previews just appear as you start dev servers.

The Autostop Lesson: Why a Running Workspace Costs Money

The autostop lesson is the bill discipline that every Coder beginner must learn in the first week: a running workspace burns compute whether you're typing or not. Coder exists to stop you paying for idle machines, and it does that with autostop — an automatic timer that stops workspaces after a period without user activity. The setting lives on the template, and the docs say it must be enabled on the template before the workspace is created — you cannot retroactively protect workspaces that are already running.

Autostop settingWhat it doesBeginner takeaway
Default autostopStops the workspace after N hours of no user activitySet this first — it's the whole point of self-hosted remote dev
Activity bumpExtends the deadline when activity is detected (default: 1 hour)Long builds keep the workspace alive; afternoons off don't
Autostop requirementForces restarts on a schedule regardless of connectionsPremium/Enterprise feature — the "fresh machine every Monday" rule
DormancyAutomatically deletes workspaces unused for a long timeStops zombie workspaces from eating disk forever

Think of autostop as the opposite of a laptop. Your laptop sleeps for free; a workspace on a cloud VM keeps the meter running. The healthy beginner pattern is: generous autostop on the template (overnight idle stops it), the workspace's Schedule tab for your own hours, and dormancy as the janitor. The one number to remember is that activity bump default of one hour — it means "I went to lunch" doesn't restart your world, but "I went home" does.

Coder vs GitHub Codespaces: Which One Should You Pick?

Coder vs GitHub Codespaces is the comparison every team runs before adopting remote dev, and the honest answer is that they solve the same problem with opposite ownership models. Codespaces is GitHub's managed SaaS: GitHub runs the infrastructure on Azure, bills you per hour of compute (Coder's comparison page attributes roughly $0.18/hr for a 2-core machine as of mid-2026), and your repos live on GitHub. Coder is the self-hosted answer: you run it on your own servers or any cloud, your code never leaves your infrastructure, and you bring whatever Git provider and whatever IDE you already use.

QuestionCoderGitHub Codespaces
Who runs the infrastructure?You — self-hosted anywhere, on-prem, or air-gappedGitHub — managed SaaS on Azure
Open source?Yes — Community edition is AGPL-3.0No
Environment definitionTerraform templates (versioned, reviewable)devcontainer.json per repo
Git providerAny — GitHub, GitLab, Bitbucket, self-hostedGitHub only
IDEAny — VS Code, JetBrains, SSH, browserVS Code or browser-first
Billing shapeYour infra bill, reduced by autostopPer-hour compute + per-GB storage

The draw-the-line rule: if your team already lives on GitHub and wants zero infrastructure to manage, Codespaces is the shorter path. If you need data residency, air-gapped networks, non-GitHub repos, or you simply refuse per-hour billing for environments you could host yourself, Coder is the self-hosted lane. The "coder vs code-server" question that also surfaces in search is smaller than it looks: code-server is just VS Code in a browser — it's a module you can put inside a Coder workspace, not a rival platform. DevPod is the closer open-source comparison (local-first remote dev), but it doesn't offer Coder's server-side templating and team management.

Coder and Tailscale: The Private-Access Sibling

Coder and Tailscale are the private-access siblings, not rivals: Coder's try.coder.app tunnel and coder ssh get you into your workspaces, but teams that want their whole fleet on a private mesh network pair Coder with Tailscale. The shape is simple — the Coder server and the workspaces join your tailnet, developers reach the dashboard without any public exposure at all, and the try.coder.app testing tunnel retires permanently. If private networking is new to you, our Tailscale beginner guide covers the mesh side; the Coder side stays exactly as this guide describes.

The Five Beginner Mistakes to Avoid

MistakeWhat happensThe fix
Skipping autostop on the templateIdle workspaces run all weekend and the cloud bill surprises youSet default autostop before creating any workspace
Using try.coder.app for productionYour dashboard depends on a vendor testing tunnelPut Coder behind your own domain with HTTPS
Editing the live workspace instead of the templateYour fixes vanish when the workspace rebuildsChange the template; recreate the workspace
Exposing the dashboard without real authAnyone on the network can create workspaces on your billStrong admin password from day one, SSO when the team grows
Treating workspaces as permanent petsStale environments pile up and nobody dares delete themTemplates are the pets; workspaces are cattle — rebuild freely

Sources

Every fact in this guide was verified from its source on November 1, 2026:

  • Coder v2.37.9 release (published October 30, 2026) — GitHub API, coder/coder releases/latest
  • Official install command curl -fsSL https://coder.com/install.sh | sh — coder.com/install.sh header and the coder/coder README
  • Quickstart arc (Docker runtime, 2+ CPU cores, 4 GB+ RAM, coder server, admin user, template builder, Docker base template, my-docker-template, 10–15 second workspace start, VS Code Desktop via the Coder extension) — coder.com/docs/get-started/
  • Template framing ("Templates describe the infrastructure for each workspace, from EC2 VMs and Kubernetes Pods to Docker containers"; "Coder is not an IaC platform. Terraform is the first IaC provisioner in Coder"; the server runs terraform apply on workspace create/start/stop) — coder.com/docs and the "write a template from scratch" tutorial
  • IDE connection methods (coder ssh, coder config-ssh + ssh coder.<workspace_name>, VS Code Desktop via the Coder extension, code-server browser, JetBrains Gateway for IntelliJ/CLion/GoLand/PyCharm/Rider/RubyMine/WebStorm/Fleet, Cursor/Windsurf/Antigravity via the extension, Coder Desktop native app with VPN tunnel and automatic port forwarding, per-user SSH key generation) — coder.com/docs/user-guides/workspace-access
  • Port-forwarding (dashboard "listening ports" window; coder port-forward <workspace> --tcp 8080) — coder.com/docs/user-guides/workspace-access
  • Autostop (default autostop idle timeout; activity bump default 1 hour; autostop requirement as Premium/Enterprise; dormancy auto-deletion; enabled on the template before workspace creation) — coder.com/docs admin template-schedule documentation
  • Pricing (Community free, AGPL-3.0, unlimited workspaces and users; Premium annually per user with no published dollar figure; free 30-day Premium trial) — coder.com/pricing
  • Coder vs GitHub Codespaces (self-hosted anywhere incl. air-gapped vs Azure SaaS; AGPL-3.0 vs closed; any Git provider and IDE; per-hour billing attribution ~$0.18/hr 2-core as of mid-2026) — coder.com/blog/coder-the-github-codespaces-alternative and Railway's Coder deploy guide
  • Fresh VPS quickstart arc (install.sh → coder server → try.coder.app tunnel → admin user → template → workspace → VS Code, updated October 31, 2026) — Rad Web Hosting blog

Frequently Asked Questions

Is Coder free?

Yes — the Community edition is free and open source under AGPL-3.0, and the pricing page's FAQ confirms you can create unlimited workspaces and users with it. That is the edition this guide installs. Coder Premium is the enterprise tier, billed annually per user, and Coder publishes no per-seat dollar figure on the pricing page — a free 30-day Premium trial is offered for evaluation. Don't invent a price you can't source.

Does Coder replace VS Code?

No — Coder runs alongside it. Coder provisions the remote environment; you still write code in VS Code Desktop (connected through the Coder extension), in a browser via code-server, or in a JetBrains IDE through Gateway. The most common beginner misunderstanding is thinking Coder is an editor; it's the machine behind the editor.

Can I use Coder without Docker?

Yes, once you move past the starter templates. Docker is the beginner runtime because the base templates assume it, but templates are Terraform — they can provision VMs on EC2 or pods on Kubernetes just as easily. The template rule doesn't change with the provisioner; only the recipe does.

How much does a Coder workspace cost to run?

Exactly what the underlying compute costs, minus whatever autostop saves you. A workspace is a container or VM on your infrastructure, so a running workspace burns compute whether you're typing or not. That's why the autostop lesson is the financial core of this guide: set the idle timer on the template, and idle machines stop themselves instead of billing you.

Coder vs code-server — aren't they the same thing?

No. code-server is VS Code running in a browser — one tool, one job. Coder is a platform for whole development environments: templates, workspaces, users, autostop, SSH access, and any IDE. code-server can live inside a Coder workspace as a module, which is exactly how the starter Docker template offers browser-based VS Code.

Featured on Twelve Tools Launch Llama Tools Launch your MCP