Ditch the Browser: Messaging from the Terminal with WhatsCLI
If you spend most of your day in a terminal, switching to a browser tab just to reply to a WhatsApp message feels like a productivity tax.
Enter WhatsCLI — a Go-based Command Line Interface (CLI) that brings your chats directly into your shell.
Built using go-whatsapp and tview, WhatsCLI is a lightweight, keyboard-centric way to stay connected without the distraction of a full web browser.
🚀 Why Use WhatsCLI?
Most “desktop” WhatsApp clients are just Electron wrappers that hog RAM. WhatsCLI takes a different approach by connecting directly to the Web App API.
Key Features
- Pure Terminal UI: Fast, responsive, and easy on system resources.
- Attachment Support: Download and open images, videos, audio, and documents through your native apps.
- Keyboard First: Navigate chats with
Tab, send images via/sendimage, and manage messages with hotkeys. - Desktop Notifications: Integrated via the
beeeplibrary so you never miss a ping. - Customizable: Supports themes and keybinding configs via a
.configfile. - Cross-Platform: Available for Windows, macOS, Linux, and Raspberry Pi.
🛠️ Getting Started
Installation
If you're on macOS or Arch Linux, setup is one line away:
- macOS:
brew install normen/tap/whatscli - Arch: Find it on the AUR.
- Others: Grab binaries from the GitHub Releases page.
Your First Login
Once installed, run whatscli. A QR code will appear in your terminal.
Pro Tip: If the QR code looks garbled, shrink your terminal’s font size or expand the window until the blocks align.
Scan it with your phone as you would for WhatsApp Web — your chats will appear instantly.
⌨️ Mastering the Workflow
WhatsCLI relies on simple shortcuts to keep you efficient:
| Action | Command/Key |
|---|---|
| Switch Panels | Tab |
| Select Message | Ctrl + w |
| Open Attachments | Select message + o |
| Copy User ID | Ctrl + c |
| Help Menu | /help or /commands |
Viewing Images in the Dark
Yes — you can see images in your CLI!
By setting up the show_command in your config to use tools like jp2a or PIXterm, WhatsCLI can render ASCII-style image previews.
⚠️ The “Hacker” Caveats
Keep in mind: this is a community-driven project, not an official Meta product.
- Backend Shifts: Changes to WhatsApp’s Web API may break functionality.
- No Automation: This isn’t a bot framework; no auto-reconnect or message scripting.
- Experimental Code: Originally a “learning Go” project, still features active TODOs.
💻 Under the Hood (For Devs)
For developers, WhatsCLI is an excellent example of Go concurrency in action:
- Main Routine: Manages UI via
tviewandcbind. - Session Manager: Operates in a separate goroutine using
go-whatsapp. - Thread Safety: Channels keep UI & network processes async and responsive.
🧠 Final Thoughts
WhatsCLI is perfect for the minimalist who wants to stay connected without leaving the command line.
It’s functional, hackable, and looks incredibly cool on a secondary monitor.
