Home CLI service railway service
Link a service to the current project and manage service operations.
Subcommand Aliases Description listlsList services in the current environment linkLink a service to the current project deleteremove, rmDelete a service from an environment statusShow deployment status for services logsView logs from a service redeployRedeploy the latest deployment restartRestart the latest deployment scaleScale a service across regions filesfileManage files in a service filesystem
Prompts you to select a service to link.
Opens an interactive TUI for browsing, downloading, uploading, editing, renaming, and deleting files in the service filesystem.
Flag Description -a, --allShow status for all services in the environment --jsonOutput in JSON format
Flag Description -d, --deploymentShow deployment logs -b, --buildShow build logs -n, --lines <N>Number of log lines to fetch (disables streaming) -f, --filter <QUERY>Filter logs using Railway's query syntax --latestShow logs from latest deployment (even if failed/building) -S, --since <TIME>Show logs since a specific time -U, --until <TIME>Show logs until a specific time --jsonOutput logs in JSON format
See railway logs for detailed usage and examples.
Flag Description -y, --yesSkip confirmation dialog --jsonOutput in JSON format
Flag Description -y, --yesSkip confirmation dialog --jsonOutput in JSON format
Argument Description REGION=REPLICASOne or more replica assignments by region.
Flag Description --jsonOutput in JSON format
See railway scale for available regions and detailed usage.
Use railway service files to manage files in a running service filesystem. The command uses the linked service by default. Pass --service, --environment, or --project to select a different target.
Subcommand Aliases Description listlsList files in a directory browsebrowserBrowse files interactively downloadDownload a file or directory uploadUpload a file or directory deleterm, removeDelete a file renamemvRename a file
Flag Description -s, --service <SERVICE>Service name or ID -e, --environment <ENVIRONMENT>Environment to use -p, --project <PROJECT_ID>Project ID to use
Argument or flag Description [REMOTE_PATH]Directory path to list. Defaults to / --jsonOutput in JSON format
Argument or flag Description <REMOTE_PATH>Remote file or directory to download [LOCAL_PATH]Local destination. Defaults to the current directory --overwrite, --overrideReplace the local path if it already exists --concurrency <N>Concurrent file downloads when downloading a directory. Defaults to 32 --jsonOutput in JSON format
Argument or flag Description <LOCAL_PATH>Local file or directory to upload <REMOTE_PATH>Remote destination path --overwriteReplace the remote path if it already exists --concurrency <N>Concurrent file uploads when uploading a directory. Defaults to 32 --jsonOutput in JSON format
Argument or flag Description <REMOTE_PATH>Remote file to delete -y, --yesSkip confirmation --jsonOutput in JSON format
railway service files delete refuses to run when invoked by an AI agent and must be run by a human.
Argument or flag Description <OLD_REMOTE_PATH>Existing remote path <NEW_REMOTE_PATH>New remote path --jsonOutput in JSON format
Argument or flag Description [REMOTE_PATH]Directory path to open. Defaults to / --editor <COMMAND>Editor command to use when editing files --concurrency <N>Concurrent file downloads. Defaults to 32