Grain / Learn / Deploying apps built by Claude Code or Codex

Switching guide

Deploying apps built by Claude Code or Codex

Deploy an app built by Claude Code or Codex through a conventional repository pipeline when it is a production service, or publish it through Grain when it is an artifact that needs a durable URL without a deploy pipeline. Grain fits internal tools, reports, prototypes and walkthroughs; Vercel, Railway and Northflank fit services whose repository, build and operations are part of the product.

Updated 2026-09-04Facts verified 2026-09-04By the Grain team

How people do this today

A coding agent starts in a repository, writes an application and proves it on localhost. The usual next step is to push a branch, connect the repository to a deployment platform, define a build, add environment variables, provision data services and choose a domain. Vercel, Railway and Northflank are general deployment destinations in this workflow. Northflank explicitly publishes guidance for deploying apps built with coding agents. This route is appropriate when the repository and pipeline are long-term operational assets. It can be excessive when the result is a review dashboard, research report or temporary internal tool whose main requirement is simply to stay open for the people using it.

The right path depends on the operational life of the output, not which agent wrote it.
PathBest fitWhat you operateWhat the viewer gets
Repository deployProduction service with established CI and ownershipRepository, build, environment, services and release policyA production application route
Grain artifactAgent-built page, app, report, prototype or scheduled toolWorkspace files, access mode and artifact stateA lasting share URL with optional data and login
Local previewDeveloper inspection during the coding sessionLaptop process and local dependenciesNothing reachable after the process stops

Where it breaks

  • A prototype inherits production ceremony. A useful one-day tool waits for repository access, build settings and infrastructure decisions that do not improve the artifact itself.
  • Local success hides missing services. The agent can make a page look complete while its data, login or scheduled refresh still depends on a laptop process. A screenshot does not reveal the gap.
  • The owner becomes the pipeline. Someone must understand why the build failed, rotate environment values and keep the deployment configuration current even when the artifact has only a few readers.
  • The output and its review split apart. The app lives at one URL, feedback lives in chat or a ticket, and the coding agent lacks a direct comment trail tied to the artifact.

The replacement workflow

  1. Classify the result. Ask whether this is a production service with its own CI, availability target and infrastructure owner, or an artifact that a known group needs to open. Keep production services on a general deployment platform.
  2. Download and authenticate. For an artifact, download the Mac app from rungrain.com and run grain login. Grain does not include an agent, so keep using your Claude Code or Codex plan.
  3. Initialize the project folder. Run grain init. It creates the workspace and writes .mcp.json for Claude Code, .codex/config.toml for Codex and .cursor/mcp.json for Cursor. Use --no-agent-config only when you do not want those files.
  4. Give the agent the whole deliverable. Prompt it: Build an account-health app from the CSV files in this folder. Include a responsive summary page, a Postgres table for owner notes, login access and a weekday refresh job. Keep adapters separate so the data source can change. This names the page, database, login and schedule rather than requesting a screenshot.
  5. Publish the workspace. After the agent writes the files, run grain push. If a pushed static workspace needs an app runtime, grain upgrade --target react-vite or grain upgrade --target nextjs promotes it; the command fails when the checkout has unpushed changes.
  6. Create a review state. Run grain checkpoint -m "account health app ready". A checkpoint marks the exact artifact state that readers evaluate.
  7. Share the first URL. Run grain share --public or grain share --password <pw>. The returned address follows https://<slug>.share.rungrain.com. Invite-only access is available when a link should be restricted to named people.
  8. Escalate when the job changes. If the artifact becomes a production service with formal CI and operational requirements, pull the files with grain pull and move them into the deployment path your team operates.

What it costs

Grain is free for unlimited published artifacts, ten sleeping sandboxes, one always-on workspace and a self-hostable core, with no card required. You pay your coding-agent provider directly; Grain does not sell or mark up tokens. Pro is $65 per user per month for more always-on workspaces, team seats, shared spaces and custom domains. Enterprise is priced by contact. Vercel, Railway and Northflank each apply their own deployment and infrastructure model, so compare them against the production resources your service actually consumes rather than inventing one cross-platform number. A repository deploy may be the better economic choice when it joins infrastructure your team already operates.

Limits

  • Grain is not a general deployment platform. Choose Vercel, Railway, Northflank or another production host when you need your own CI and infrastructure lifecycle.
  • The Mac app is available first on macOS. Windows has a waitlist, while the self-hostable core runs on Linux.
  • Custom domains require Pro and are configured by CNAME. The default share address is on share.rungrain.com.
  • Public shares are reachable by anyone with the link. Use password or invited access for private material.
  • The agent still owns implementation quality. Publishing an app does not prove its security, correctness or production readiness.

Frequently asked questions

Can Grain deploy an app built by Codex?

Grain publishes files produced by Codex or another CLI coding agent as an artifact. Use a general deployment platform instead when the app is a production service with its own CI.

Does Grain work with Claude Code?

Yes. The init command writes Claude Code MCP configuration to .mcp.json, alongside configuration for Codex and Cursor.

Can a Grain app have a database and login?

Yes. Apps can have a Postgres database, logins and scheduled jobs. Static artifacts can remain simple pages.

When should I move from an artifact to a deploy pipeline?

Move when the app becomes a production service that needs repository-governed builds, independent infrastructure policy and an operational owner.

Can I export the files later?

Yes. Artifacts are files you can pull through the CLI. Published artifacts stay published if you stop paying.

Publish the app at the layer it needs

Start with a durable artifact URL, and keep production deployment for services that need a pipeline.

Free forever. No card. Bring your own agent.

Sources · facts verified 2026-09-04