Skip to content

Warp Agent CLI > Reference

Warp Agent CLI reference

Open in ChatGPT ↗
Ask ChatGPT about this page
Open in Claude ↗
Ask Claude about this page
Copied!

Reference for the Warp Agent CLI: command-line flags, environment variables, slash commands, keyboard shortcuts, and troubleshooting.

This page is a lookup reference for the Warp Agent CLI: the flags and environment variables the warp command accepts, every slash command available in a session, the default keyboard shortcuts, and fixes for common issues.

Running warp with no flags starts an interactive session in the current directory. The following flags change how the CLI starts or run a one-off action and exit.

Resumes a previous conversation by its conversation token.

Terminal window
warp --resume CONVERSATION_TOKEN

CONVERSATION_TOKEN is the token the CLI prints when you exit a session (“To continue this conversation, run: warp --resume ...”). You can also reopen past conversations from inside a session with /conversations. See conversations in the Warp Agent CLI for how persistence and resuming work.

Authenticates with a Warp API key instead of the interactive browser login. Useful on hosts where a browser sign-in is inconvenient.

Terminal window
warp --api-key YOUR_API_KEY

The key can also be supplied through the WARP_API_KEY environment variable. Create a key in the Warp app under Settings > Platform; see the API keys reference for details.

Securely stores a model-provider API key for Bring Your Own API Key (BYOK), then exits. The provider is one of openai, anthropic, or google.

Terminal window
warp --set-provider-api-key anthropic

The CLI prompts for the key with masked input, so the key never appears in your shell history. When stdin is piped, the key is read from stdin instead:

Terminal window
warp --set-provider-api-key anthropic < key.txt

See models and usage for how stored keys affect billing.

Removes a stored model-provider API key, then exits. The provider is one of openai, anthropic, or google.

Terminal window
warp --clear-provider-api-key anthropic

Prints the installed version and exits.

Terminal window
warp --version

Prints usage information for all flags and exits.

Terminal window
warp --help
  • WARP_API_KEY - Warp API key for non-interactive authentication. Equivalent to passing --api-key.
  • WARP_TUI_DISABLE_AUTOUPDATE - Set to any value to disable background auto-updates for that launch. See Updating for how updates work.

Type / at the start of the input to open the slash command menu, then keep typing to filter it. Commands that take an argument show a hint after the command name. Angle brackets mark required arguments; square brackets mark optional ones.

CommandArgumentDescription
/add-api-key<openai|anthropic|google>Securely store a model-provider API key
/agent[prompt]Start a new conversation
/auto-approveToggle auto-approve for agent actions
/clear[prompt]Clear the transcript and start a new conversation
/clear-provider-api-key<openai|anthropic|google>Remove a stored model-provider API key
/compact[instructions]Free up context by summarizing the conversation history
/conversationsOpen conversation history
/costToggle per-response credit usage details
/create-new-project<description>Have the agent walk you through creating a new coding project
/exitExit the CLI
/export-to-clipboardExport the current conversation to the clipboard as Markdown
/export-to-file[filename]Export the current conversation to a Markdown file
/handoff[prompt]Hand off this conversation to a cloud agent
/logoutLog out of Warp
/mcpView and manage MCP servers
/modelSwitch the base agent model
/natural-language-detectionToggle natural language detection for shell input
/new[prompt]Start a new conversation (alias for /agent)
/plan[task]Ask the agent to research and create a plan for a task
/skillsInvoke a skill
/statuslineConfigure the statusline
/theme<auto|light|dark>Set the color theme
/versionShow the installed version
/view-logsBundle your logs into a zip archive
/voiceStart voice input (Ctrl+S)

Skills also appear in the same menu under their own names, so you can invoke a skill directly as /skill-name. See context in the Warp Agent CLI for how skills are discovered.

Press ? on an empty input to open the contextual shortcuts panel inside the CLI. The tables below list the default bindings.

ShortcutAction
Ctrl+CStop the current response, or clear the input; press again within a second to exit
Ctrl+DExit when the input is empty (deletes the next character otherwise)
?Show the shortcuts panel (on an empty input)
/Open the slash command menu
!Enter shell mode (Esc returns to agent input)
Open the conversation list (on an empty input)
Browse prompt and command history
EscDismiss the open menu, or leave shell mode
Ctrl+Shift+IToggle auto-approve
Ctrl+Shift+PExpand or collapse the latest plan
Ctrl+SStart voice input
Ctrl+V / Ctrl+Shift+VPaste from the clipboard, including images
TabFocus attached images when present; complete shell commands in shell mode

These bindings apply while the agent is waiting for you to approve an action. See permissions and profiles for how approvals work.

ShortcutAction
EnterConfirm the selected response
EscReject or cancel the request
eEdit the proposed action, or expand and collapse all diffs in a file-edit approval
Ctrl+EnterApprove a blocked terminal-use action

While the agent is running an interactive terminal command, or you have taken control of one:

ShortcutAction
Ctrl+CInterrupt the running command, or take control from the agent
Ctrl+GHand control back to the agent

When you run multiple agents, a tab bar appears above the session. See cloud and orchestration for details.

ShortcutAction
Shift+↑Focus the agent tab bar
/ or Tab / Shift+TabSwitch between agents
Return focus to the input
EscReturn to the main agent

The input supports familiar readline-style editing:

ShortcutAction
Shift+Enter, Ctrl+J, or Alt+EnterInsert a newline
Ctrl+A / HomeMove to the start of the line
Ctrl+E / EndMove to the end of the line
Ctrl+B / Ctrl+FMove left / right
Alt+B / Alt+F (or Alt+← / Alt+→)Move one word left / right
Ctrl+W or Alt+BackspaceDelete the previous word
Alt+D or Alt+DeleteDelete the next word
Ctrl+KDelete to the end of the line
Ctrl+UDelete to the start of the line
Ctrl+YPaste the last deleted text
Ctrl+Z / Ctrl+Shift+ZUndo / redo
Shift+← / Shift+→ / Shift+↑ / Shift+↓Extend the selection
Ctrl+Shift+ASelect all
Ctrl+Shift+CCopy the selection
Ctrl+XCut the selection

For mouse support, completions, and other input behavior, see input and editing.

This section covers common Warp Agent CLI issues: gathering logs for a bug report, fixing sign-in problems, resuming conversations, and keeping the CLI up to date.

When something goes wrong, logs are the fastest way to help the Warp team diagnose the problem.

Run /view-logs in a session to bundle the current session’s log and recent previous sessions into a timestamped zip archive. The CLI reveals the archive in your file manager and shows the saved path in the footer, so you can attach it to a bug report or share it with support.

On macOS, Warp Agent CLI logs are stored in ~/Library/Logs/warp-cli/. Logs rotate per session, and only a limited number of recent sessions are kept. The /view-logs archive is written to the same directory.

The Warp Agent CLI signs you in with a browser-based flow: it opens a verification page (or shows you the URL and a code to enter) and continues once you approve the sign-in. On a remote or browser-less machine, the CLI can’t launch a browser, but the sign-in screen still shows the verification URL and code.

  1. Open the displayed URL in a browser on any device, including another machine.
  2. Enter the code shown in the CLI.
  3. Return to the CLI; it proceeds automatically once the sign-in is approved.

For machines where the browser flow isn’t practical, authenticate non-interactively with an API key instead, using warp --api-key or the WARP_API_KEY environment variable. See command-line flags.

The sign-in attempt was rejected or timed out; the message shows the underlying cause.

  1. Press Ctrl+C to exit.
  2. Run warp again to restart the sign-in flow.
  3. If the failure persists, check your network connection and any proxy or firewall that could block access to Warp’s servers.
  1. Run /logout in a session. The CLI signs you out, opens your browser to complete the sign-out on Warp’s website, and returns to the sign-in screen.
  2. Sign in with the account you want.

”Could not restore conversation” when resuming

Section titled “”Could not restore conversation” when resuming”

warp --resume failed to load the conversation for the given token, for example because the token is malformed or the conversation is no longer available.

  1. Press Ctrl+C to exit, then run warp to start normally.
  2. Check the token against the resume command printed when you exited the original session.
  3. If the conversation exists locally, open it with /conversations instead. See conversations in the Warp Agent CLI.

The Warp Agent CLI keeps itself up to date. Installed builds check for updates in the background, download new versions, and apply them the next time you launch warp; a running session is never interrupted.

To check which version you’re running, use /version in a session, or run:

Terminal window
warp --version

To disable background updates for a single launch, set the WARP_TUI_DISABLE_AUTOUPDATE environment variable to any value. To disable them persistently, turn off the autoupdate setting in the settings file; see configuration.

If an install becomes corrupted, re-running the install command from the quickstart replaces it with the latest version.

  • Sending us feedback - How to reach Warp support and share feedback.
  • Known issues - Current known issues across Warp.
  • GitHub issues - Search existing reports or file a new one; attach the /view-logs archive to bug reports.