GH-DISCUSSION-CREATE(1) GitHub CLI manual GH-DISCUSSION-CREATE(1)

gh-discussion-create - Create a new discussion (preview)

gh discussion create [flags]

Create a new GitHub Discussion in a repository.

With '--title', '--body', and '--category', a discussion is created non-interactively. Omitting any of these flags triggers interactive prompts when connected to a terminal.

Body for the discussion
Read body text from file (use "-" to read from stdin)
Category name or slug for the discussion
Labels to apply to the discussion
Select another repository using the [HOST/]OWNER/REPO format
Title for the discussion

0: Successful execution

1: Error

2: Command canceled

4: Authentication required

NOTE: Specific commands may have additional exit codes. Refer to the command's help for more information.

# Create interactively
$ gh discussion create
# Create non-interactively
$ gh discussion create --title "My question" --category "Q&A" --body "Details here"

gh-discussion(1)

Jun 2026