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

gh-discussion-view - View a discussion (preview)

gh discussion view {<number> | <discussion-url> | <comment-id> | <comment-url>} [flags]

Display the title, body, and other information about a discussion.

To see the comments on a discussion, pass --comments. A few latest replies of each comment will also be retrieved regardless of the selected ordering.

To see the full reply thread of a single comment, pass a comment node ID or comment URL as the argument instead of a discussion (e.g., https://github.com/OWNER/REPO/discussions/123#discussioncomment-456).

Pagination and ordering can be controlled via --order, --limit, and --after flags.

Use --web to open the discussion or comment in a web browser instead.

Cursor for the next page
View discussion comments
Filter JSON output using a jq expression
Output JSON with the specified fields
Maximum number of comments or replies to fetch
Order of comments or replies: {oldest|newest}
Select another repository using the [HOST/]OWNER/REPO format
Format JSON output using a Go template; see "gh help formatting"
Open a discussion in the browser

answerChosenAt, answerChosenBy, answered, author, body, category, closed, closedAt, comments, createdAt, id, labels, locked, number, reactionGroups, state, stateReason, title, updatedAt, url

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.

# View a discussion by number
$ gh discussion view 123
# View a discussion by URL
$ gh discussion view https://github.com/OWNER/REPO/discussions/123
# View with comments
$ gh discussion view 123 --comments
# View with oldest comments first
$ gh discussion view 123 --comments --order oldest
# Limit to 10 comments
$ gh discussion view 123 --comments --limit 10
# Fetch the next page of comments
$ gh discussion view 123 --comments --after CURSOR
# View the reply thread of a comment by node ID
$ gh discussion view DC_abc123
# View the reply thread of a comment by URL
$ gh discussion view 'https://github.com/OWNER/REPO/discussions/123#discussioncomment-456'
# Paginate through replies
$ gh discussion view DC_abc123 --limit 10 --after CURSOR
# Open in browser
$ gh discussion view 123 --web

gh-discussion(1)

Jun 2026