ntro CLI

Command reference

Every public ntro command and option, grouped by task.

How to read this page

  • <argument> is required; [argument] is optional. In a terminal, leaving out an [argument] makes the CLI ask you to pick or type it. Automation may need to pass it explicitly.
  • Tables list only options specific to each command. Common options such as --team and --json are in CLI configuration.
  • Options on a command group (builds, domains, env, and so on), such as --app, apply to all of its subcommands.
  • Every command shows usage and examples with --help.

Login, status, and updates

CommandDescription
ntro loginLog in through the browser. --no-browser: print the URL and code without opening a browser.
ntro logoutLog out and delete local login data.
ntro whoamiShow the logged-in account and whether its email is verified.
ntro tokenPrint a five-minute access token for calling the REST API directly. Uses NITROSHIP_TOKEN when set. See API authentication.
ntro statusCheck API health and login status.
ntro healthcheckCheck the API's /healthz endpoint.
ntro updateUpdate to the latest version. --check: only check. Alias upgrade.

Automatic update notices: at most once a day, ntro checks for a new version in the background and tells you after the command finishes, without slowing the command down. It skips the check with --json, in CI (CI not empty), when stderr is not a terminal, for dev and prerelease builds, and for --help, --version, and shell completion. Set NITROSHIP_NO_UPDATE_NOTIFIER=1 to turn it off.

Teams

CommandDescription
ntro teams listTeams you belong to
ntro teams create [name]Create a team. --slug <slug> sets the slug; it is required if no slug can be derived from the name.
ntro teams switch [team]Change your default team. Alias ntro switch.
ntro teams members listTeam members
ntro teams members add [email]Send an invitation. --role member|billing|viewer. Automation must pass both email and role.
ntro teams members role [user] [role]Change a member's role. The user is an ID or email.
ntro teams members remove [user]Remove a member. Automation needs the target and --yes.
ntro teams invitations create [email]Send an invitation. --role defaults to member.
ntro teams invitations listInvitations. Alias ls.
ntro teams invitations revoke [invitationId|email]Cancel a pending invitation. Automation needs the target and --yes. Alias rm.

Only the team owner can manage invitations and members. Invitees join only after accepting, and invitations expire after seven days. See Teams and roles for ownership transfer and the full rules. teams is also available as team.

CommandDescription
ntro apps listApps in the team. Alias ls.
ntro apps create [slug]Create an app and link the current folder. --no-link: skip the link.
ntro apps show [app]App details. Uses the linked app if omitted.
ntro apps delete [app]Delete an app. In a terminal you confirm by typing its slug; automation needs --yes. Aliases rm, remove.
ntro link [app]Link the current folder to an app. Pick from a list if omitted.
ntro unlinkRemove the current folder's link. The app is not deleted.

ntro unlink --json prints {"unlinked":true,"appId":"<id>"} (plus teamId when known) after removing a link, or {"unlinked":false} when there was none. How links work is covered in CLI configuration > App links.

Deploy

ntro deploy [folder]     # or: ntro [folder]

Running plain ntro with no arguments deploys the current folder.

OptionDescription
--app <id|slug>The app to deploy to. Optional in a linked folder.
--prod / --preview / --target production|previewWhere to deploy. Use only one. Without any, the first deployment goes to production and later ones to preview.
--no-waitQueue the build and return immediately.
--timeout <duration>How long to wait at most. Default 10 minutes.
--yesProceed without prompts. An unlinked folder then needs --app.
--local, --image, --bundle-dir, --entrypoint, --skip-buildFor building and uploading yourself. See below.
--regions, --tier, --min-instances <0..32>, --max-instances <1..32>, --portCompute settings. Direct uploads only.

By default the CLI streams the build log and waits until the deployment is ready or failed. With --json, progress goes to stderr and the result is printed to stdout as one JSON object: a Deployment after waiting, or a Build with --no-wait.

Choosing how to deploy

RouteExampleUse it when
Remote build (default)ntro deploy .Almost always. Upload your source and Nitroship builds it.
Local buildntro deploy . --localYou want to build a supported static or managed Node.js app (including Next.js) on your machine, or upload a ready-made static folder as-is.
Reuse a local buildntro deploy . --local --skip-buildYou already built a supported managed framework app and want to upload its output without rebuilding.
Container imagentro deploy --image sha256:<digest>You built an OCI image yourself.
Node.js bundlentro deploy --bundle-dir ./out --entrypoint 'node server.js'You want to choose the folder of files to run and the command that starts them.

Deployment asset uploads reuse content already stored for the app. Progress shows the file bytes actually sent and how many unchanged files were skipped; Node.js bundles are still uploaded in full. Uploads continue through the Nitroship API, and older servers automatically receive all files.

  • --image and --bundle-dir cannot be combined. --bundle-dir always needs --entrypoint.
  • --local supports static and node-server presets, plus the dedicated Next.js adapter. It rejects container and container-static presets, including generated static toolchain builders. Dockerfile builds also require hosted builds. Remove --local to let Nitroship build the source. See Build framework.
  • Remote builds do not accept compute flags; use App Settings > Compute in the console or nitroship.json. See Compute settings.
  • --tier takes a tier name offered by the platform. The default is standard, with others such as large; the available names and their CPU and memory are shown in the console and by GET /v1/compute/options. Disabled tiers cannot be used for new deployments.
  • ntro registry login only prints the Docker login command for pushing images to the Nitroship registry (with --json: registry, username, and password). The output contains a password, so keep it out of shared logs.

Manage deployments and logs

CommandDescription
ntro deployments listDeployments. Filter with --target production|preview. Aliases ntro ls, ntro list.
ntro deployments show <short-id|id>Deployment details
ntro inspect [short-id|id]Deployment details. --logs: include events.
ntro promote <short-id|id>Promote a ready deployment to production. --yes.
ntro rollback <short-id>Send production back to an earlier deployment. --yes.
ntro redeploy <short-id|id>Create a new deployment from a ready deployment's files. --prod or --preview.
ntro logs [short-id|id]Deployment events. --follow: keep streaming.
ntro builds listRemote builds
ntro builds logs [id]Build events. --follow: keep streaming.
ntro builds cancel [id]Cancel a queued or running build. Automation needs the ID and --yes.

All of these accept --app. See Managing deployments for how promote and rollback work.

Domains

CommandDescription
ntro domains add [hostname]Add a domain
ntro domains listDNS and certificate status. Alias ls.
ntro domains verify <hostname>Request ownership verification. --wait, --timeout <duration>.
ntro domains remove [hostname]Remove a domain. --yes. Alias rm.

See Custom domains for details.

Environment variables

CommandDescription
ntro env ls [production|preview]List. Alias list.
ntro env add <NAME> [production|preview]Add a value; secret by default. --no-sensitive (plain value), --sensitive, --force (overwrite).
ntro env rm <NAME> [production|preview]Remove. --yes. Alias remove.
ntro env pull [file]Save plain values to a file. --environment production|preview, --yes (overwrite).
ntro env run -- <command> [args...]Run a command with plain values set. --environment production|preview.

See Environment variables for details.

Cache

CommandDescription
ntro purge <url|/path>--app, --wait, --yes: invalidate one exact URL or path. Instead of an argument, choose --prefix <path>, --glob <pattern>, repeated --tag <tag> (up to 16 tags), --host <hostname>, or --all. Add --delete for response-cache logical deletion rather than stale/background invalidation; existing prerender behavior is unchanged.

See Cache invalidation for details.

Usage and billing

CommandDescription
ntro usageTeam usage and estimated charges. --from, --to (YYYY-MM-DD or RFC3339), --by region|app|day.
ntro billingTeam plan and payment status
ntro invoicesInvoices

Charges shown by ntro usage are estimates in the team's billing currency, not a credit balance. 1 credit = 1 USD; local-currency value uses the operator's published fixed credit price, not live FX. Monthly plan credits cover usage only and do not roll over; operator-granted credits reduce invoice totals across currencies, oldest first. Receipts are sent to the billing customer's email address when positive-total invoices become paid.

See Usage and billing for details.

On this page