.nh .TH "GH-DISCUSSION-VIEW" "1" "Jun 2026" "" "GitHub CLI manual" .SH NAME gh-discussion-view - View a discussion (preview) .SH SYNOPSIS \fBgh discussion view { | | | } [flags]\fR .SH DESCRIPTION Display the title, body, and other information about a discussion. .PP To see the comments on a discussion, pass \fB--comments\fR\&. A few latest replies of each comment will also be retrieved regardless of the selected ordering. .PP 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., \fBhttps://github.com/OWNER/REPO/discussions/123#discussioncomment-456\fR). .PP Pagination and ordering can be controlled via \fB--order\fR, \fB--limit\fR, and \fB--after\fR flags. .PP Use \fB--web\fR to open the discussion or comment in a web browser instead. .SH OPTIONS .TP \fB--after\fR \fB\fR Cursor for the next page .TP \fB-c\fR, \fB--comments\fR View discussion comments .TP \fB-q\fR, \fB--jq\fR \fB\fR Filter JSON output using a jq expression .TP \fB--json\fR \fB\fR Output JSON with the specified fields .TP \fB-L\fR, \fB--limit\fR \fB (default 30)\fR Maximum number of comments or replies to fetch .TP \fB--order\fR \fB (default "newest")\fR Order of comments or replies: {oldest|newest} .TP \fB-R\fR, \fB--repo\fR \fB<[HOST/]OWNER/REPO>\fR Select another repository using the [HOST/]OWNER/REPO format .TP \fB-t\fR, \fB--template\fR \fB\fR Format JSON output using a Go template; see "gh help formatting" .TP \fB-w\fR, \fB--web\fR Open a discussion in the browser .SH JSON FIELDS \fBanswerChosenAt\fR, \fBanswerChosenBy\fR, \fBanswered\fR, \fBauthor\fR, \fBbody\fR, \fBcategory\fR, \fBclosed\fR, \fBclosedAt\fR, \fBcomments\fR, \fBcreatedAt\fR, \fBid\fR, \fBlabels\fR, \fBlocked\fR, \fBnumber\fR, \fBreactionGroups\fR, \fBstate\fR, \fBstateReason\fR, \fBtitle\fR, \fBupdatedAt\fR, \fBurl\fR .SH EXIT CODES 0: Successful execution .PP 1: Error .PP 2: Command canceled .PP 4: Authentication required .PP NOTE: Specific commands may have additional exit codes. Refer to the command's help for more information. .SH EXAMPLE .EX # 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 .EE .SH SEE ALSO \fBgh-discussion(1)\fR