>_ ghcli.com
ghcli / Auth & Config / gh extension install

gh extension install

Add new gh commands from the community

gh extension install adds community-built commands to gh, so tools like gh dash or gh copilot become first-class gh subcommands. Install from any repository that follows the gh-extension convention, pin a version, and upgrade or remove them later.

Quick answer
gh extension install dlvhdr/gh-dash

Syntax

gh extension install <repository> [flags]

Examples

Install an extension from a repo

gh extension install dlvhdr/gh-dash

Pin to a specific release

gh extension install owner/gh-tool --pin v1.2.0

List installed extensions

gh extension list

Upgrade every extension

gh extension upgrade --all

Remove an extension

gh extension remove dash

Options & flags

FlagWhat it does
--pinPin the extension to a specific release tag or commit.
--forceForce installation even if the extension seems already installed.

How to use gh extension install, step by step

  1. Find an extension repo named gh-something.
  2. Run gh extension install owner/gh-something.
  3. Invoke it as a subcommand, e.g. gh dash.
  4. Keep them current with gh extension upgrade --all.

Common errors and fixes

there is already an installed extension that provides the "dash" command

You already have an extension using that name. Remove the old one with gh extension remove dash, or use --force.

failed to install: repository does not contain a gh- prefixed executable

That repo isn't a valid gh extension. Confirm the name follows the gh- convention and includes an executable.

Related commands

Frequently asked questions

How do I install a GitHub CLI extension?

Run gh extension install owner/repo, for example gh extension install dlvhdr/gh-dash. The extension then works as a gh subcommand like gh dash.

How do I update GitHub CLI extensions?

Run gh extension upgrade --all to update every installed extension, or name one to upgrade it individually.

How do I remove an extension?

Use gh extension remove <name>. List what's installed first with gh extension list.