Share a snippet

Paste code or text, press Create gist and share the link. No account needed.

Up to 20 files and 1.0 MiB in total. Tab indents; press Esc, then Tab, to move on.

From your terminal

Share a file

curl -T main.go https://gist.uug.lol

Share command output

make test 2>&1 | curl -T - "https://gist.uug.lol/?filename=test.log"

Several files, with a description

curl -F file=@main.go -F file=@go.mod \
     -F description="Repro for #42" -F expires=1w https://gist.uug.lol

JSON API

curl https://gist.uug.lol/api/v1/gists -d '{
  "description": "Hello",
  "files": {"hello.py": {"content": "print(\"hi\")"}}
}'

Terminal uploads print the gist's URL. The Gist-Edit-Key response header (curl -i), or edit_key in JSON, lets you change it later with PATCH or DELETE /api/v1/gists/<id> and Authorization: Bearer <key>. curl https://gist.uug.lol/<id> prints a single-file gist.