Nhost CLI Reference
nhost - A new cli application
SYNOPSIS
Section titled “SYNOPSIS”nhost
[--branch]=[value][--dot-nhost-folder]=[value][--help|-h][--local-subdomain]=[value][--nhost-folder]=[value][--project-name]=[value][--root-folder]=[value][--version|-v]DESCRIPTION
Section titled “DESCRIPTION”Nhost CLI tool
Usage:
nhost [GLOBAL OPTIONS] [command [COMMAND OPTIONS]] [ARGUMENTS...]GLOBAL OPTIONS
Section titled “GLOBAL OPTIONS”—branch="": Git branch name. If not set, it will be detected from the current git repository. This flag is used to dynamically create docker volumes for each branch. If you want to have a static volume name or if you are not using git, set this flag to a static value. (default: <current-git-branch>) [$BRANCH]
—dot-nhost-folder="": Path to .nhost folder (default: “.nhost”) [$NHOST_DOT_NHOST_FOLDER]
—help, -h: show help
—local-subdomain="": Local subdomain to reach the development environment (default: “local”) [$NHOST_LOCAL_SUBDOMAIN]
—nhost-folder="": Path to nhost folder (default: “nhost”) [$NHOST_NHOST_FOLDER]
—project-name="": Project name (default: <project-directory-name>) [$NHOST_PROJECT_NAME]
—root-folder="": Root folder of project (default: ”.”) [$NHOST_ROOT_FOLDER]
—version, -v: print the version
COMMANDS
Section titled “COMMANDS”config
Section titled “config”Perform config operations
—help, -h: show help
default
Section titled “default”Create default configuration and secrets
—help, -h: show help
help, h
Section titled “help, h”Shows a list of commands or help for one command
example
Section titled “example”Shows an example config file
—help, -h: show help
help, h
Section titled “help, h”Shows a list of commands or help for one command
Apply configuration to cloud project
—help, -h: show help
—subdomain="": Subdomain of the Nhost project to apply configuration to. Defaults to linked project [$NHOST_SUBDOMAIN]
—yes: Skip confirmation [$NHOST_YES]
help, h
Section titled “help, h”Shows a list of commands or help for one command
Get cloud configuration
—help, -h: show help
—subdomain="": Pull this subdomain’s configuration. Defaults to linked project [$NHOST_SUBDOMAIN]
—yes: Skip confirmation [$NHOST_YES]
help, h
Section titled “help, h”Shows a list of commands or help for one command
Shows configuration after resolving secrets
—help, -h: show help
—subdomain="": Show this subdomain’s rendered configuration. Defaults to base configuration [$NHOST_SUBDOMAIN]
help, h
Section titled “help, h”Shows a list of commands or help for one command
validate
Section titled “validate”Validate configuration
—help, -h: show help
—subdomain="": Validate this subdomain’s configuration. Defaults to linked project [$NHOST_SUBDOMAIN]
help, h
Section titled “help, h”Shows a list of commands or help for one command
Edit base configuration or an overlay
—editor="": Editor to use (default: “vim”) [$EDITOR]
—help, -h: show help
—subdomain="": If specified, edit this subdomain’s overlay, otherwise edit base configuation [$NHOST_SUBDOMAIN]
help, h
Section titled “help, h”Shows a list of commands or help for one command
help, h
Section titled “help, h”Shows a list of commands or help for one command
deployments
Section titled “deployments”Manage deployments
—help, -h: show help
List deployments in the cloud environment
—help, -h: show help
—subdomain="": Project’s subdomain to operate on, defaults to linked project [$NHOST_SUBDOMAIN]
help, h
Section titled “help, h”Shows a list of commands or help for one command
View deployments logs in the cloud environment
—follow: Specify if the logs should be streamed
—help, -h: show help
—subdomain="": Project’s subdomain to operate on, defaults to linked project [$NHOST_SUBDOMAIN]
—timeout="": Specify the timeout for streaming logs (default: 5m0s)
help, h
Section titled “help, h”Shows a list of commands or help for one command
[EXPERIMENTAL] Create a new deployment
—follow: Specify if the logs should be streamed. If set, the command will wait for the deployment to finish and stream the logs. If the deployment fails the command will return an error.
—help, -h: show help
—message="": Commit message
—ref="": Git reference [$GITHUB_SHA]
—subdomain="": Project’s subdomain to operate on, defaults to linked project [$NHOST_SUBDOMAIN]
—timeout="": Specify the timeout for streaming logs (default: 5m0s)
—user="": Commit user name [$GITHUB_ACTOR]
—user-avatar-url="": Commit user avatar URL
help, h
Section titled “help, h”Shows a list of commands or help for one command
help, h
Section titled “help, h”Shows a list of commands or help for one command
Operate local development environment
—help, -h: show help
compose
Section titled “compose”docker compose wrapper, sets project name and compose file automatically
—help, -h: show help
help, h
Section titled “help, h”Shows a list of commands or help for one command
hasura
Section titled “hasura”hasura-cli wrapper
—help, -h: show help
help, h
Section titled “help, h”Shows a list of commands or help for one command
help, h
Section titled “help, h”Shows a list of commands or help for one command
Start local development environment
—apply-seeds: Apply seeds. If the .nhost folder does not exist, seeds will be applied regardless of this flag [$NHOST_APPLY_SEEDS]
—auth-port="": If specified, expose auth on this port. Not recommended (default: 0)
—ca-certificates="": Mounts and everrides path to CA certificates in the containers [$NHOST_CA_CERTIFICATES]
—dashboard-version="": Dashboard version to use (default: “nhost/dashboard:2.47.0”) [$NHOST_DASHBOARD_VERSION]
—disable-tls: Disable TLS [$NHOST_DISABLE_TLS]
—down-on-error: Skip confirmation [$NHOST_YES]
—functions-port="": If specified, expose functions on this port. Not recommended (default: 0)
—hasura-console-port="": If specified, expose hasura console on this port. Not recommended (default: 0)
—hasura-port="": If specified, expose hasura on this port. Not recommended (default: 0)
—help, -h: show help
—http-port="": HTTP port to listen on (default: 443) [$NHOST_HTTP_PORT]
—postgres-port="": Postgres port to listen on (default: 5432) [$NHOST_POSTGRES_PORT]
—run-service="": Run service to add to the development environment. Can be passed multiple times. Comma-separated values are also accepted. Format: /path/to/run-service.toml[:overlay_name] [$NHOST_RUN_SERVICE]
—storage-port="": If specified, expose storage on this port. Not recommended (default: 0)
Start local development environment connected to an Nhost Cloud project (BETA)
—apply-seeds: Apply seeds. If the .nhost folder does not exist, seeds will be applied regardless of this flag [$NHOST_APPLY_SEEDS]
—ca-certificates="": Mounts and everrides path to CA certificates in the containers [$NHOST_CA_CERTIFICATES]
—dashboard-version="": Dashboard version to use (default: “nhost/dashboard:2.47.0”) [$NHOST_DASHBOARD_VERSION]
—disable-tls: Disable TLS [$NHOST_DISABLE_TLS]
—down-on-error: Skip confirmation [$NHOST_YES]
—hasura-console-port="": If specified, expose hasura console on this port. Not recommended (default: 0)
—help, -h: show help
—http-port="": HTTP port to listen on (default: 443) [$NHOST_HTTP_PORT]
—postgres-url="": Postgres URL [$NHOST_POSTGRES_URL]
—subdomain="": Project’s subdomain to operate on, defaults to linked project [$NHOST_SUBDOMAIN]
help, h
Section titled “help, h”Shows a list of commands or help for one command
help, h
Section titled “help, h”Shows a list of commands or help for one command
Stop local development environment
—help, -h: show help
—volumes: Remove volumes
help, h
Section titled “help, h”Shows a list of commands or help for one command
Show logs from local development environment
—help, -h: show help
help, h
Section titled “help, h”Shows a list of commands or help for one command
docker-credentials
Section titled “docker-credentials”Perform docker-credentials operations
—help, -h: show help
configure
Section titled “configure”Install credentials helper and configure docker so it can authenticate with Nhost’s registry
—docker-config="": Path to docker config file (default: $HOME/.docker/config.json) [$DOCKER_CONFIG]
—help, -h: show help
—no-interactive: Do not prompt for confirmation [$NO_INTERACTIVE]
help, h
Section titled “help, h”Shows a list of commands or help for one command
help, h
Section titled “help, h”Shows a list of commands or help for one command
Model Context Protocol (MCP) related commands
—config-file="": Configuration file path. Defaults to $NHOST_DOT_NHOST_FOLDER/nhost-mcp.toml [$NHOST_MCP_CONFIG_FILE]
—help, -h: show help
config
Section titled “config”Generate and save configuration file
—confirm: Skip confirmation prompt [$CONFIRM]
—help, -h: show help
Dump the configuration to stdout for verification
—help, -h: show help
help, h
Section titled “help, h”Shows a list of commands or help for one command
help, h
Section titled “help, h”Shows a list of commands or help for one command
Starts the MCP server
—bind="": Bind address in the form $host:$port. If omitted use stdio [$BIND]
—help, -h: show help
help, h
Section titled “help, h”Shows a list of commands or help for one command
Generate GraphQL schema for Nhost Cloud
—help, -h: show help
—nhost-pat="": Personal Access Token [$NHOST_PAT]
—with-mutations: Include mutations in the generated schema [$WITH_MUTATIONS]
help, h
Section titled “help, h”Shows a list of commands or help for one command
help, h
Section titled “help, h”Shows a list of commands or help for one command
Initialize a new Nhost project
—help, -h: show help
—remote: Initialize pulling configuration, migrations and metadata from the linked project [$NHOST_REMOTE]
help, h
Section titled “help, h”Shows a list of commands or help for one command
List remote apps
—help, -h: show help
help, h
Section titled “help, h”Shows a list of commands or help for one command
Link local app to a remote one
—help, -h: show help
help, h
Section titled “help, h”Shows a list of commands or help for one command
Access embedded documentation
—help, -h: show help
list, ls
Section titled “list, ls”List all documentation pages
—grouped: Show pages organized by section
—help, -h: show help
—summary: Show page descriptions
help, h
Section titled “help, h”Shows a list of commands or help for one command
search, s, find
Section titled “search, s, find”Search documentation pages
—help, -h: show help
—limit, -n="": Maximum number of results to return (default: 5)
help, h
Section titled “help, h”Shows a list of commands or help for one command
show, view
Section titled “show, view”Display contents of a documentation page
—help, -h: show help
—raw: Show raw MDX content including frontmatter
help, h
Section titled “help, h”Shows a list of commands or help for one command
help, h
Section titled “help, h”Shows a list of commands or help for one command
Perform operations on Nhost Run
—help, -h: show help
config-show
Section titled “config-show”Shows Run service configuration after resolving secrets
—config="": Service configuration file (default: “nhost-run-service.toml”) [$NHOST_RUN_SERVICE_CONFIG]
—help, -h: show help
—overlay-name="": If specified, apply this overlay [$NHOST_RUN_SERVICE_ID, $NHOST_SERVICE_OVERLAY_NAME]
help, h
Section titled “help, h”Shows a list of commands or help for one command
config-deploy
Section titled “config-deploy”Deploy service configuration
—config="": Service configuration file (default: “nhost-run-service.toml”) [$NHOST_RUN_SERVICE_CONFIG]
—help, -h: show help
—service-id="": Service ID to update. Applies overlay of the same name [$NHOST_RUN_SERVICE_ID]
help, h
Section titled “help, h”Shows a list of commands or help for one command
config-edit
Section titled “config-edit”Edit service configuration
—config="": Service configuration file (default: “nhost-run-service.toml”) [$NHOST_RUN_SERVICE_CONFIG]
—editor="": Editor to use (default: “vim”) [$EDITOR]
—help, -h: show help
—overlay-name="": If specified, apply this overlay [$NHOST_RUN_SERVICE_ID, $NHOST_SERVICE_OVERLAY_NAME]
help, h
Section titled “help, h”Shows a list of commands or help for one command
config-edit-image
Section titled “config-edit-image”Edits configuration file and sets the image
—config="": Service configuration file (default: “nhost-run-service.toml”) [$NHOST_RUN_SERVICE_CONFIG]
—help, -h: show help
—image="": Image to use [$NHOST_RUN_SERVICE_IMAGE]
help, h
Section titled “help, h”Shows a list of commands or help for one command
config-pull
Section titled “config-pull”Download service configuration
—config="": Service configuration file (default: “nhost-run-service.toml”) [$NHOST_RUN_SERVICE_CONFIG]
—help, -h: show help
—service-id="": Service ID to update [$NHOST_RUN_SERVICE_ID]
help, h
Section titled “help, h”Shows a list of commands or help for one command
config-validate
Section titled “config-validate”Validates service configuration after resolving secrets
—config="": Service configuration file (default: “nhost-run-service.toml”) [$NHOST_RUN_SERVICE_CONFIG]
—help, -h: show help
—overlay-name="": If specified, apply this overlay [$NHOST_SERVICE_OVERLAY_NAME]
—service-id="": If specified, apply this overlay and remote secrets for this service [$NHOST_RUN_SERVICE_ID]
help, h
Section titled “help, h”Shows a list of commands or help for one command
config-example
Section titled “config-example”Shows an example config file
—help, -h: show help
help, h
Section titled “help, h”Shows a list of commands or help for one command
Outputs environment variables. Useful to generate .env files
—config="": Service configuration file (default: “nhost-run-service.toml”) [$NHOST_RUN_SERVICE_CONFIG]
—help, -h: show help
—overlay-name="": If specified, apply this overlay [$NHOST_RUN_SERVICE_ID, $NHOST_SERVICE_OVERLAY_NAME]
—prepend-export: Prepend ‘export’ to each line [$NHOST_RuN_SERVICE_ENV_PREPEND_EXPORT]
help, h
Section titled “help, h”Shows a list of commands or help for one command
help, h
Section titled “help, h”Shows a list of commands or help for one command
secrets
Section titled “secrets”Manage secrets
—help, -h: show help
create
Section titled “create”Create secret in the cloud environment
—help, -h: show help
—subdomain="": Project’s subdomain to operate on, defaults to linked project [$NHOST_SUBDOMAIN]
help, h
Section titled “help, h”Shows a list of commands or help for one command
delete
Section titled “delete”Delete secret in the cloud environment
—help, -h: show help
—subdomain="": Project’s subdomain to operate on, defaults to linked project [$NHOST_SUBDOMAIN]
help, h
Section titled “help, h”Shows a list of commands or help for one command
List secrets in the cloud environment
—help, -h: show help
—subdomain="": Project’s subdomain to operate on, defaults to linked project [$NHOST_SUBDOMAIN]
help, h
Section titled “help, h”Shows a list of commands or help for one command
update
Section titled “update”Update secret in the cloud environment
—help, -h: show help
—subdomain="": Project’s subdomain to operate on, defaults to linked project [$NHOST_SUBDOMAIN]
help, h
Section titled “help, h”Shows a list of commands or help for one command
help, h
Section titled “help, h”Shows a list of commands or help for one command
Perform software management operations
—help, -h: show help
uninstall
Section titled “uninstall”Remove the installed CLI from system permanently
—force: Force uninstall without confirmation [$NHOST_FORCE_UNINSTALL]
—help, -h: show help
help, h
Section titled “help, h”Shows a list of commands or help for one command
upgrade
Section titled “upgrade”Upgrade the CLI to the latest version
—help, -h: show help
help, h
Section titled “help, h”Shows a list of commands or help for one command
version
Section titled “version”Show the current version of Nhost CLI you have installed
—help, -h: show help
help, h
Section titled “help, h”Shows a list of commands or help for one command
help, h
Section titled “help, h”Shows a list of commands or help for one command
Login to Nhost
—email="": Email address [$NHOST_EMAIL]
—help, -h: show help
—password="": Password [$NHOST_PASSWORD]
—pat="": Use this Personal Access Token instead of generating a new one with your email/password [$NHOST_PAT]
help, h
Section titled “help, h”Shows a list of commands or help for one command
gen-docs
Section titled “gen-docs”Generate markdown documentation for the CLI
—help, -h: show help
help, h
Section titled “help, h”Shows a list of commands or help for one command
help, h
Section titled “help, h”Shows a list of commands or help for one command