×

注意!页面内容来自https://github.com/features/copilot/cli/,本站不储存任何内容,为了更好的阅读体验进行在线解析,若有广告出现,请及时反馈。若您觉得侵犯了您的利益,请通知我们进行删除,然后访问 原网页

Skip to content
<> /* Override primer focus outline color for marketing header dropdown links for better contrast */ [data-color-mode="light"] .HeaderMenu-dropdown-link:focus-visible, [data-color-mode="light"] .HeaderMenu-trailing-link a:focus-visible { outline-color: var(--color-accent-fg); }
Copilot CLI

Less // TODO: more done

Run a GitHub-native agent in your terminal that works directly with your issues and pull requestsexecutes across a /fleet of parallelized subagentsand carries you from /plan to merged code.

curl -fsSL https://gh.io/copilot-install | bash

Read the documentation. Included in Copilot FreeProPro+Businessand Enterprise subscriptions.

Get Copilot CLI

Read the documentation. Available with Copilot FreeProPro+Businessand Enterprise.

Use any /modelparallelize with /fleet

Use /model to switchthen /fleet to execute in parallel or run multiple models at once.

/resume where you left off

Return to long-running work and keep moving. Memory and compaction keep sessions from collapsing under their own history.

CLI to /IDEand back again

Start in the CLI with a /planthen open the work in VS Code to refine code directly.

Go from /plan to pull request

Compare plans and run /fleet across your preferred models to execute with parallelized subagents. Refine in your /IDE and ship your pull request on GitHub.

Work with your issues via native GitHub /mcp support

Built on GitHub’s native /mcp integrationCopilot can search issuesanalyze labels and activityand summarize scope so you can move from backlog to implementation without context hunting.

Screenshot of a terminal where an AI assistant displays two assigned GitHub issues: #4 'Implement featured game on landing page' and #3 'Add email subscription feature for game updates.' A command prompt waits for input below.

/plan with a team of agents. Execute with autopilot.

Shift+Tab into plan mode to outline the workuse /model to compare approachesand then Shift+Tab into autopilot mode when you want Copilot to carry the task forward without step-by-step approval.

Terminal screenshot showing GitHub Copilot connected to various MCP servers and a user writing a prompt about adding email-based product update subscriptions.

Shape behavior with /agent and /skills

Use AGENTS.md and Agent Skills to define custom instructions and tool accessso behavior stays consistent across modelssessionsand delegated work.

Terminal screenshot showing a menu of custom agentswith the Default agent selected.

/delegate workreview the /diff

Create a branchimplement a changeand open a pull request with a single command. Stay in control while /fleet coordinates subagents in the background.

Terminal prompt asking whether to send a session to GitHubshowing a migration message and Yes/No options.

GitHub native via /mcp

GitHub’s native /mcp server lets you work with issuesbranchesand pull requestsnot just edit files.

Works inside your existing guardrails

Branch protectionsrequired checksand organization policies work. Copilot Business or Enterprise settings apply automatically.

Get early access to experimental capabilities

/experimental show offers access to preview features as we build them. Use /changelog to see the latest updates.

Build on the same agentic runtime with the Copilot SDK

If your application has logicit can have an agent. Install Copilot CLI (npm install -g @github/copilot) to get started.

Pixel‑ illustration resembling a terminal windowfeaturing the text 'GitHub Copilot SDK' in large blocky letters alongside a pixel‑art Copilot character with blue goggles and purple headphones.

Move from issue to commit without leaving your shell

Install Copilot CLI with npm install -g @github/copilot and run /plan on your next task.

Read the documentation

Resources on GitHub Copilot CLI

GitHub CLI documentation

Learn how to set up Copilot CLI and use the terminal for your agentic workflows.

Read the docs

GitHub MCP Registry

Discover an ecosystem of partner and community-driven MCP servers to connect to Copilot CLI.

Discover the MCP Registry

Build an app with Copilot CLI

Follow a guided GitHub Skills module and create an application step by step using Copilot CLI in your terminal.

Start the course

Frequently asked questions

Getting StartedPricing & Access

Who can access GitHub Copilot CLI?

Copilot CLI is included as a core feature of all GitHub Copilot plans (FreeProPro+Businessand Enterprise).

How much does it cost to use Copilot CLI?

Copilot CLI access is included as part of your Copilot subscription. Each interaction with the agent draws on your respective plan’s premium request allowance. For additional information on billingplease refer to our documentation.

How do I install and set up Copilot CLI?

There are multiple ways to install and set up Copilot CLI. Install via npm with npm install -g @github/copilotthen authenticate using your existing GitHub credentials. The CLI automatically inherits your organization's Copilot policies and governance settings. Please see the installation guide to read options for HomebrewWinGetand more.

I have a Copilot Business or Enterprise license. Will I have access to Copilot CLI?

Yes. Copilot CLI works with your existing Copilot Business or Enterprise subscription — no additional billing or setup required. Howeveryour organization's admin needs to enable Copilot CLI.

What operating systems are supported?

Copilot CLI supports macOSLinuxand Windows.

Capabilities & Functionality

Can I use Copilot CLI with any code editor?

Copilot CLI operates independently in your terminal and can modify files that any editor can then displaymaking it useful regardless of your editor choice — especially for editors that don't have official Copilot extensions.

Will Copilot CLI integrate directly into VS Code?

Yesyou can interact with Copilot CLI in the VS Code integrated terminal and in the VS Code chat panel. Please see our docs page for more information.

Can I extend Copilot CLI with custom tools?

YesCopilot CLI supports Model Context Protocol (MCP) server integrationsskillsand pluginsallowing you to add custom capabilities and contextual richness tailored to your unique development environment.

Which models can I access with Copilot CLI?

Copilot CLI supports models from multiple foundation model providerssuch as AnthropicGoogleand OpenAI. You can switch models per task or use multiple models for the same task when needed.

What types of development tasks work best with Copilot CLI?

Copilot CLI excels at legacy codebase navigationnew repository creationcross-platform development setupand multi-step implementationsand any scenario requiring autonomous task execution with terminal-native workflows.

Does Copilot CLI support subagents or multi-agent workflows?

Yes. Copilot CLI supports subagents and multi‑agent workflows. With /fleetyou can run the same task across multiple subagents in parallel and converge on one decision‑ready resultwith full control over what’s applied.

How does chat history and session persistence work?

Copilot CLI maintains session persistence within and across sessionsallowing you to build on previous conversations and maintain context throughout your development workflow.

Security & Governance

How does Copilot CLI handle security and compliance?

Copilot CLI automatically inherits your organization's existing Copilot governance policies. It's built on GitHub's trusted platform infrastructure with the same security standards and compliance that protect millions of developers.

How does file modification and command execution work?

Every file change and command execution requires your explicit approval before being applied. You maintain complete visibility and control over all autonomous actions.

Getting StartedPricing & Access

Who can access GitHub Copilot CLI?

Copilot CLI is included as a core feature of all GitHub Copilot plans (FreeProPro+Businessand Enterprise).

How much does it cost to use Copilot CLI?

Copilot CLI access is included as part of your Copilot subscription. Each interaction with the agent draws on your respective plan’s premium request allowance. For additional information on billingplease refer to our documentation.

How do I install and set up Copilot CLI?

There are multiple ways to install and set up Copilot CLI. Install via npm with npm install -g @github/copilotthen authenticate using your existing GitHub credentials. The CLI automatically inherits your organization's Copilot policies and governance settings. Please see the installation guide to read options for HomebrewWinGetand more.

I have a Copilot Business or Enterprise license. Will I have access to Copilot CLI?

Yes. Copilot CLI works with your existing Copilot Business or Enterprise subscription — no additional billing or setup required. Howeveryour organization's admin needs to enable Copilot CLI.

What operating systems are supported?

Copilot CLI supports macOSLinuxand Windows.