Blog / OpenCode
OpenCode free model: DeepSeek V4.1 Flash with dl opencode
dl opencode starts your own OpenCode on dl's free tier: DeepSeek V4.1 Flash under provider dl, GPT-6 once you've used dl a while. No config changes.

Run dl opencode instead of opencode. dl starts the OpenCode you already have with the free tier added under a provider called "dl". The free tier serves DeepSeek V4.1 Flash, and GPT-6 Luna, Sol and Astra once you've used dl for a while (or with your own key). No OpenCode file is read or changed, and the free key only works while that run lasts.
Last checked: 19 November 2026, against dl 0.41.0 and the installer README.
How it works
dl opencode follows the same steps as dl claude:
- Signs you in to the free tier. It is the same GitHub sign-in that
dland Autopilot use, and it runs first if you are not signed in. - Finds OpenCode. dl never installs OpenCode. If
opencodeis not on your PATH, it prints the official install command and stops. - Gets a short-lived key. The key lasts 15 minutes. dl refreshes it while OpenCode runs and ends it when OpenCode exits.
- Starts OpenCode with that key. Every argument after
opencodegoes to OpenCode unchanged, and OpenCode's exit code becomes dl's.
There is no local proxy. OpenCode talks to the free tier's OpenAI-compatible endpoint, the same one Autopilot uses. dl configures OpenCode through two environment variables, for that one process only:
| Variable | What it holds |
|---|---|
OPENCODE_CONFIG_CONTENT |
Inline config that adds the "dl" provider, lists its models with their context and output limits, and picks the default model |
DL_FREE_TIER_KEY |
The 15-minute key, which that config reads |
OpenCode merges inline config above your global and project config, so your own providers and settings stay. If you set OPENCODE_CONFIG_CONTENT yourself, dl leaves yours out for that run and says so. The code is in src/laptop/opencode.ts.
Install and run
curl -fsSL https://dl.new | sh # install dl
dl opencode # OpenCode on the free tier
If you already use Node, npm install -g directionallylocal installs the same dl. dl opencode needs dl 0.41.0 or later. dl update brings an older install up to date.
If OpenCode is missing, dl prints the official commands:
curl -fsSL https://opencode.ai/v2/install | bash
# or
npm install -g @opencode/cli
Arguments pass straight through:
dl opencode run "fix the failing test" # one-shot
dl opencode --continue # continue the last session
The models
The free tier serves DeepSeek V4.1 Flash, under provider "dl" in OpenCode's /models. Your own providers stay in the list too, on your own keys.
| Model in /models | Context window | Max output | Images |
|---|---|---|---|
dl/deepseek/deepseek-v4.1-flash-1017 (free) |
1,048,576 | 65,536 | No |
GPT-6 Luna, GPT-6.1 Sol and GPT-6 Astra show up under "dl" too for accounts that have used dl for a while or paid. Otherwise, use them with your own OpenAI or OpenRouter key.
The limits come from dl's built-in model list in opencode.ts. dl asks the free tier for its current list first, so a new model can show up without a new dl. Session titles use DeepSeek, because OpenCode sends titles to its small model.
OpenCode 1 and OpenCode 2
dl checks opencode --version and handles both major versions.
| OpenCode 1 | OpenCode 2 | |
|---|---|---|
Reads OPENCODE_CONFIG_CONTENT |
Yes | Yes |
| Extra flag from dl | None | --standalone |
| Why | It needs nothing extra | Sessions normally run in a shared background server that would not see the config |
--server URL |
Not allowed with dl opencode |
Not allowed with dl opencode |
--standalone gives OpenCode 2 a private server that inherits dl's environment. If dl cannot read the version, it assumes OpenCode 2. --server URL is refused because dl cannot configure a server it didn't start.
Scripts: close stdin for opencode run
When stdin is not a terminal, opencode run reads it as extra input. In OpenCode 1 it reads stdin to the end, so a script that leaves stdin open can hang. You can see this in run.ts at v1.19.6. Newer OpenCode 2 builds wait only briefly when a message is given, according to their run.ts. Closing stdin works for both:
dl opencode run "update the changelog" < /dev/null
Limits to know about
Free tokens only work through dl. The key exists only while dl opencode runs. OpenCode started any other way uses your own providers.
Half the free allowance. Claude Code and OpenCode get half the free allowance; Autopilot gets it all. When OpenCode's half runs out, type dl to keep going in Autopilot.
DeepSeek reads text only. To attach images, use your own key with a model that reads images.
Weekly allowance
Sign in with GitHub and you get free DeepSeek V4.1 Flash tokens every week. How many depends on your GitHub account. The week resets every Monday at 00:00 UTC. Need more? Type /request in dl and tell us what you're building.
What dl sends
dl sends a session start (repeated every few hours in long sessions) and a session end, with counts only, plus a key refresh every few minutes. Prompts and code go to the model. They never go into dl's logs. The privacy policy has the details.
Install dl with curl -fsSL https://dl.new | sh, then run dl opencode.
FAQs
Does dl opencode change my OpenCode config?
No. No OpenCode file is read or written. dl passes inline config in an environment variable for that run only, and OpenCode merges it above your own config.
Which model does it start with?
DeepSeek V4.1 Flash, under provider "dl" in /models. GPT-6 is free too for accounts that have used dl for a while or paid; otherwise it needs your own key.
Why does my script hang on dl opencode run?
opencode run is probably waiting for stdin to close. Add < /dev/null to the command.
Can I keep using my own providers?
Yes. They stay in /models on your own keys. Only the "dl" provider uses free tokens.
When does my allowance come back?
Every Monday at 00:00 UTC.