A native macOS port and process monitor for developers.
View active ports, identify processes, kill operations, and track specific ports — all from a lightweight menubar-friendly app.
Grab the latest .dmg from Releases, mount it, and drag ThePort into your Applications folder. No brew, no signing headaches — just open and go.
Ever run lsof -i :3000 just to find out what's hogging a port? ThePort replaces that workflow with a real-time UI that shows every active TCP connection on your Mac, which process owns it, and lets you kill it in one click.
| Feature | Description |
|---|---|
| Port Monitoring | Real-time view of all active TCP ports on your system |
| Process Identification | See which processes (Node, Chrome, Postgres, etc.) own each port |
| Kill Processes | Terminate processes directly — graceful (SIGTERM) or force (SIGKILL) |
| Search & Filter | Filter by state (Listening, Established) or search by port, process name, or address |
| Watchlist | Track specific ports you care about with custom names and priority levels |
| Auto-Refresh | Automatic updates every 5 seconds (configurable) |
| Light & Dark Theme | Follows system appearance or toggle manually |
| Low Resource Usage | ~94 MB memory, 0% CPU when idle |
ThePort is designed to stay out of your way. Here's what to expect:
| Metric | Value |
|---|---|
| Memory (idle) | ~94 MB |
| CPU (idle) | 0% |
| CPU (during refresh) | < 1% spike for ~100ms |
| Refresh interval | Every 5 seconds (configurable) |
| App size (DMG) | ~5 MB |
| Startup time | < 1 second |
| Background scanning | netstat + lsof via Process() — no persistent daemons |
| Network usage | None — all data comes from local system commands |
| Disk usage | Minimal — only a small SQLite file for the watchlist |
ThePort spawns short-lived
netstatandlsofsubprocesses on each refresh cycle. Between cycles, CPU usage drops to 0%. No background daemons, no polling threads, no wake locks.
ThePort uses two macOS system commands under the hood:
netstat -an -p tcp— lists all active TCP connections and listening portslsof -i -P -n -F— enriches each port entry with process info (PID, name, user)
These run on a configurable timer and feed a clean, filterable SwiftUI interface.
| Component | Technology |
|---|---|
| Language | Swift 5.9+ |
| UI | SwiftUI |
| Database | SQLite via GRDB.swift 7.x |
| Port Scanning | netstat · lsof |
| Build System | Tuist |
| CI/CD | GitHub Actions |
| Distribution | DMG |
- macOS 14.0 (Sonoma) or later
- Xcode 15+
- Tuist 4.x (
brew tap tuist/tuist && brew install tuist)
git clone https://github.com/bujosa/ThePort.git
cd ThePort
# Install dependencies & generate Xcode project
make install
make generate
# Build and run (debug)
make build
make run| Command | Description |
|---|---|
make install |
Install Swift package dependencies |
make generate |
Generate Xcode workspace via Tuist |
make build |
Build debug configuration |
make run |
Build and launch the app |
make release |
Build release configuration |
make dmg |
Create distributable .dmg |
make clean |
Clean build artifacts and regenerate |
make edit |
Open Tuist project for editing |
make icons |
Regenerate app icons |
ThePort/
├── Project.swift # Tuist project definition
├── Tuist/Package.swift # Dependencies (GRDB.swift)
├── Makefile # Build automation
├── .github/workflows/release.yml # CI/CD — builds DMG on tag push
├── scripts/
│ ├── create-dmg.sh # DMG packaging script
│ └── generate-icons.swift # App icon generator
└── ThePort/
├── Sources/
│ ├── ThePortApp.swift # App entry point
│ ├── Models/ # Data models (PortInfo, ProcessInfo, etc.)
│ ├── Services/
│ │ ├── PortService.swift # Port scanning via netstat/lsof
│ │ └── DatabaseService.swift # SQLite via GRDB (watchlist persistence)
│ ├── Theme/ # Light/Dark theme system
│ └── Views/
│ ├── ContentView/ # Root navigation
│ ├── Sidebar/ # Navigation sidebar
│ ├── PortList/ # Port listing with filters
│ ├── Watchlist/ # Watchlist management
│ ├── ProcessDetail/ # Process details modal
│ └── Components/ # Reusable UI components
└── Resources/
└── Assets.xcassets/ # App icons & colors
Watchlist data is stored locally in a SQLite database:
~/Library/Application Support/ThePort/db.sqlite
No cloud services, no accounts, no telemetry. Everything stays on your machine.
- Fork the repo
- Create a feature branch (
git checkout -b feature/awesome-thing) - Commit your changes
- Push and open a Pull Request
MIT License — see LICENSE for details.