Terminal notification guide

Send Android notifications from an SSH terminal

Bubble SSH turns supported OSC terminal sequences into Android notifications. The simplest app-specific form is OSC 777: send “notify”, an optional title, and a message separated by semicolons. OSC 9 and OSC 99 are also supported.

Updated September 7, 20265 minute read
01

Quick example with OSC 777

Run this only in a Bubble SSH terminal. It prints an OSC control sequence with a title and body; Bubble SSH consumes it and shows an Android notification.

printf '\033]777;notify;Deploy complete;Production finished successfully\007'
02

Supported notification forms

Bubble SSH recognizes three OSC codes. Your shell or program must write the sequence to the connected terminal exactly as bytes.

  • OSC 9: the payload becomes the notification body
  • OSC 99: supports metadata, title/body parts, optional Base64 content, and multipart IDs
  • OSC 777: expects notify;title;body, or notify;body when no title is needed
03

Why notifications may disappear inside tmux

Terminal multiplexers decide which control sequences reach the outer terminal. Standard tmux setups commonly do not pass these OSC notification sequences through, so Bubble SSH never receives them.

If you need both a persistent server-side session and Bubble SSH notifications, use a multiplexer that transparently forwards OSC sequences, such as zmx, or configure and test an explicit passthrough suitable for your environment.

04

Use notifications for completion, not streaming logs

A notification works best for a meaningful state change: a deployment completed, a backup failed, or a long build finished. Keep regular progress in the terminal and emit one bounded message at the end.

  • Keep title and body short
  • Avoid repeated notifications inside tight loops
  • Never include credentials or terminal output by default
  • Test while the bubble is collapsed and while another app is foreground

Keep the context. Keep the terminal.

Put your next SSH session one tap away.

Get Bubble SSH