.nh .TH "GT-SSH-KEY-CREATE" "1" "Nov 2026" "gitea-cli" "gitea-cli Manual" .SH NAME gt-ssh-key-create - Add an SSH public key from a file or stdin .SH SYNOPSIS \fBgt ssh-key create [] [flags]\fP .SH DESCRIPTION Add an SSH public key to your account. Without a file, or with -, the key is read from stdin. .PP The title defaults to the key's comment, such as alice@laptop, or else to this computer's name. .SS JSON FIELDS .EX created_at, fingerprint, id, key, read_only, title .EE .SH OPTIONS \fB-h\fP, \fB--help\fP[=false] help for create .PP \fB-t\fP, \fB--title\fP="" Key title (defaults to the key comment, then the computer's name) .SH OPTIONS INHERITED FROM PARENT COMMANDS \fB--csv\fP[=""] Output CSV with the specified comma-separated \fBfields\fR, or all fields .PP \fB--debug\fP[=false] Log the method, URL, status, and duration of each HTTP request to stderr .PP \fB--host\fP="" Gitea instance \fBURL\fR, including any base path .PP \fB--interactive\fP[=false] Allow prompts with machine output .PP \fB-q\fP, \fB--jq\fP="" Filter JSON output using a jq \fBexpression\fR; implies --json .PP \fB--json\fP[=""] Output JSON with the specified comma-separated \fBfields\fR, or all fields .PP \fB--no-input\fP[=false] Disable prompts and implicit editor/browser interactions .PP \fB--sudo\fP="" Perform API requests as this \fBuser\fR (requires an administrator account) .PP \fB--user\fP="" Account \fBname\fR on the selected instance .SH EXAMPLE .EX $ gt ssh-key create ~/.ssh/id_ed25519.pub $ gt ssh-key create ~/.ssh/id_ed25519.pub --title "Work laptop" $ cat key.pub | gt ssh-key create .EE .SH SEE ALSO \fBgt-ssh-key(1)\fP