Port Killer
2025shippedA lightweight macOS menu bar app that shows your development ports and lets you kill them with one click—built with Tauri for a tiny 2.5MB footprint.
// GitHub
// Problem
Every developer knows the pain: you're switching between projects, and port 3000 is already in use. The fix? Remember the arcane lsof -i :3000 command, find the PID in the output, then run kill -9 on it. Or open Activity Monitor and hunt through hundreds of processes. I found myself asking Claude Code to do this for me constantly—which felt ridiculous for such a common operation. The existing solutions were either heavyweight Electron apps or required terminal gymnastics.
// Solution
A single-purpose menu bar utility that does exactly one thing well: show your dev ports and kill them with one click. No hunting for PIDs, no terminal commands, no bloated app taking up 200MB of memory. Just a ⚡ icon in your menu bar that lists your running dev servers (3000, 5173, 8080, etc.) and lets you terminate them instantly.
// What I Built
A native macOS app built on Tauri 2.0—the Rust-based alternative to Electron that compiles to a 2.5MB binary instead of a 150MB monster. The frontend is React with TypeScript and Tailwind CSS, while the backend uses Rust to execute lsof for port scanning and kill for process termination. The app runs as a system tray icon, showing a dropdown of active development ports filtered to common dev server ranges. Each port displays the process name and protocol, with a one-click kill button. The main window (optional) adds search/filter capabilities and groups multiple connections from the same process. Auto-refresh keeps the list current without manual intervention.
// Technologies
Tauri 2.0
Rust-based desktop app framework that compiles to native binaries—2.5MB vs Electron's 150MB+. Uses macOS private APIs for system tray integration and native-feeling menus
Rust
Backend commands for process management—executing lsof -i -P -n for port scanning, parsing output to extract PIDs, and safely terminating processes with proper validation
React + TypeScript
Frontend UI with custom hooks for port data management (usePorts) and auto-refresh logic. Type-safe interfaces for port information (port number, process name, PID, protocol, state)
Tailwind CSS
Rapid UI styling for the port list, search bar, and status indicators—different colors for LISTEN vs ESTABLISHED states
macOS Native Commands
Uses lsof for network connection discovery and kill for process termination—no external dependencies, just system utilities wrapped in a friendly UI
// Lessons Learned
- 01Tauri is genuinely impressive for developer tools. The 2.5MB binary size compared to Electron's bloat makes it practical to build single-purpose utilities that you'd never justify with a 150MB footprint. The Rust backend is overkill for simple apps, but the result feels native.
- 02'Vibe coding' works for well-scoped problems. This took about 30 minutes from idea to working app because the problem was dead simple: list ports, kill processes. No auth, no database, no complex state management. Claude could scaffold the entire thing because there were no ambiguous requirements.
- 03The best tools solve your own annoyances first. I built this because I was literally asking AI assistants to run lsof commands for me multiple times a day. That friction was the entire product spec. If you're repeatedly doing something tedious, that's a signal.
- 04Menu bar apps have a surprisingly high utility-to-complexity ratio. The system tray pattern—always accessible, never in the way—is perfect for developer utilities. The hardest part was learning Tauri's tray API, not building the actual functionality.