npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

portki-tui

v0.1.4

Published

A Linux TUI for inspecting and safely stopping local port listeners.

Readme


portki is built for developer machines where ports are constantly occupied by Next.js, NestJS, Vite, Docker, Podman, databases, and background services. The scanner reads the Linux /proc filesystem directly, meaning normal usage has zero dependencies on lsof, ss, or fuser.

Preview

PORTKI TUI preview


Features

🔍 Core Inspector

  • Dense lazygit-style UI: Interactive listener list, summary charts, and modal confirmations.
  • Traffic Inspector: View active socket connections (ESTABLISHED, TIME_WAIT, etc.) for the selected port.
  • Live Process Logs: View the stdout/stderr stream from processes, including native Docker and Podman container logs.
  • Direct /proc Parsing: Extreme speed and low resource usage without executing external utilities.

🛡️ Conservative Kill Flow

  • Wholesome Safety Model: Never sends SIGKILL first. Sends SIGTERM, waits, and requires a second confirmation before sending SIGKILL to remaining processes.
  • Group Killing: Select multiple listeners with <space> and terminate them collectively.
  • Protected Processes: Automatically blocks attempts to kill PID 1, protected system processes, or the running portki instance.
  • Risk Assessment: Highlights infrastructure listeners (databases, reverse proxies, web servers, SSH) as high-risk targets.

🔌 Extensible Integrations

  • App Detection: Built-in detection signatures for Next.js, NestJS, Vite, Node, Bun, Docker, Podman, Postgres, Redis, Nginx, Caddy, Apache, system services, and more.
  • Docker/Podman Enrichment: Matches published ports back to their parent container name, ID, and image.
  • CLI & Scripting: Output structured JSON for scripts with portki list --json.

Installation

You can install portki using either the standalone binary or npm:

| Feature | Standalone Binary (Recommended) | NPM Package (portki-tui) | | :--- | :--- | :--- | | Dependencies | None (Zero-dependency binary) | Node.js >=20 and Bun | | Updates | Via install script | npm update -g portki-tui | | Target OS | Linux (x64 / arm64) | Linux |

Option 1: Standalone Binary (Zero dependencies)

Run the automated installer:

curl -fsSL https://raw.githubusercontent.com/ricardojparram/portki/main/install.sh | sh

The installer automatically detects your processor architecture (x86_64 vs arm64), downloads the compiled standalone binary from the latest GitHub Release, and registers it under your path.

Option 2: NPM Package

npm install -g portki-tui

[!IMPORTANT] If installing via npm, you must have Bun installed on your system to run the interactive TUI.


Usage

Interactive TUI Mode

Launch the main TUI:

portki

Scriptable Commands

Output active listeners in JSON format:

portki list --json

Verify your environment permissions and check for optional diagnostic tools:

portki doctor

Kill specific ports or PIDs using the same safe policy as the TUI:

portki kill 3000 --safe
portki kill 3000 --safe --force

Controls & Keyboard Shortcuts

Navigation & Actions

| Shortcut | Action | | :--- | :--- | | j / k | Navigate up / down in the listener list | | g / G | Jump to the top / bottom of the list | | <space> | Select / Deselect multiple items | | d | Initiate safe kill flow on selected items | | r | Manually reload / refresh listeners | | / | Enter Live Filter mode | | : | Open Command Line mode | | Tab / h / l | Alternate tabs in the Inspector pane (DetailsConnectionsLogs) | | ? | Toggle Help Modal | | q / Esc | Quit / Close active Modal |

Command Mode (:)

Press : to open the command line in the TUI:

  • :kill <port> - Kill a listener on a port.
  • :kill-pid <pid> - Kill a specific process ID.
  • :p <port> or :private <port> - Reserve/monopolize a local port.
  • :release <port> - Free a reserved port.
  • :refresh - Reload listeners list.
  • :quit - Exit portki.

Development

portki uses Node.js for lightweight CLI/JSON scripts and Bun for the high-performance OpenTUI FFI runtime.

# Clone the repository
git clone https://github.com/ricardojparram/portki.git
cd portki

# Install dependencies
bun install

# Run test suite
bun test

# Run build & compilation
bun run build

Run your local build:

bun run build
./bin/portki

License

MIT License. See LICENSE for details.