GH-PROJECT-ITEM-ARCHIVE(1)

πŸ’… GH-PROJECT-ITEM-ARCHIVE(1) β€” the GitHub CLI manual, bestie edition πŸŽ€

okay so picture this: you're deep in a GitHub project board, there's an item you literally never want to see again, and you need it gone but like… archivally. That's this command. Welcome to gh-project-item-archive from the GitHub CLI manual β€” yes queen, we're archiving things today 🌸


✨ NAME ✨

gh-project-item-archive β€” archive an item in a project πŸ—‚οΈπŸ’–

Like, gently yeet it out of the way. Not delete, archive. There's a difference and it's giving main character energy.


πŸ¦‹ SYNOPSIS πŸ¦‹

gh project item-archive [<number>] [flags]

That [<number>] is optional-ish vibes and the [flags] are where all the ~power~ lives. Keep reading, i promise it slays πŸ”₯


πŸ‘‘ OPTIONS πŸ‘‘

  • --format <string> β€” output format, and the only one listed here is {json}. So: json, or… json. periodt ✨
  • --id <string> β€” the ID of the item you're archiving. this is the actual item, not the project number, don't mix them up bestie 😭
  • -q, --jq <expression> β€” filter that JSON output using a jq expression. yes, you can pipe your little heart out 🫢
  • --owner <string> β€” login of the owner. use "@me" for the current user. hi, it's me, i'm the user, it's me πŸ’…
  • -t, --template <string> β€” format the JSON output using a Go template. see "gh help formatting" for the lore πŸ“–
  • --undo β€” unarchive an item. the uno reverse card of this whole situation πŸ”„ (ngl, the "no take-backs" girlies are gonna need this one)
⚠️ real talk: --undo is literally the opposite of what this command's name says. it's not a bug, it's a feature, and honestly? iconic.

πŸ’€ EXIT CODES πŸ’€

vibe check on how it went:

  • 0 β€” successful execution. slay! you ate! πŸŽ‰
  • 1 β€” error. something went wrong, and it's not you, it's the command 😭
  • 2 β€” command canceled. we just… stopped. no notes πŸ™ˆ
  • 4 β€” authentication required. log in, bestie, the door's locked πŸ”
πŸ“Œ NOTE: specific commands may have additional exit codes. refer to the command's help for more information. iykyk 🧚

🌈 EXAMPLE 🌈

# Archive an item in the current user's project "1"
$ gh project item-archive 1 --owner "@me" --id <item-ID>

look at that. project 1, owner "@me", and the <item-ID> gets archived. chef's kiss, no cap πŸ“β­


πŸ”₯ SEE ALSO πŸ”₯

  • gh-project(1) β€” go read that one too, it's the parent energy this whole thing runs on πŸ’œ

so yeah, that's the whole page πŸ¦‹ archive responsibly, use --undo when you regret it, and remember: you're doing amazing, sweetie πŸ’–

β€” with love, from GitHub CLI v2.102.0, dated Oct 2026 πŸŽ€βœ¨ (yes, from the future, don't worry about it πŸ’…)

πŸ“¦ where this page comes from