Kubeshark — API Traffic Viewer for Kubernetes
eBPF-powered, sidecar-free traffic viewer for Kubernetes that decodes HTTP, gRPC, Kafka, Redis and more across every pod in the cluster.
What it is
Kubeshark is an open-source real-time API traffic viewer for Kubernetes. Think of it as Wireshark for your cluster -- it captures pod-to-pod, pod-to-service, and external traffic at the node level using eBPF and raw sockets, then decodes application protocols in a browser-based UI.
It is built for platform engineers, SREs, and developers who need to debug microservice communication without modifying workloads or installing service mesh sidecars. Kubeshark decodes HTTP/1.1, HTTP/2, gRPC, Kafka, Redis, AMQP, MongoDB wire protocol, DNS, and raw TCP.
How it saves time or tokens
Traditional Kubernetes traffic debugging involves adding sidecar proxies, enabling verbose logging in each service, or deploying a full service mesh. Kubeshark eliminates all of that. A single kubeshark tap command deploys a DaemonSet that immediately starts capturing traffic across all pods in the cluster.
The built-in query language (KFL) lets you filter traffic in real time, so you can isolate the exact API call causing issues without sifting through logs. You can also export to PCAP files for offline analysis in Wireshark.
How to use
- Install the CLI:
sh <(curl -Ls https://kubeshark.co/install). - Run
kubeshark tapagainst your current kube-context to capture traffic across all pods, or scope to a namespace withkubeshark tap -n my-ns. - Open the browser UI at
http://localhost:8899to view decoded traffic with filters.
Example
# Install the CLI
sh <(curl -Ls https://kubeshark.co/install)
# Tap all pods in the cluster
kubeshark tap
# Tap a specific namespace
kubeshark tap -n my-namespace
# Tap pods matching a pattern
kubeshark tap 'api-server.*'
# Open the UI at http://localhost:8899
# Use KFL to filter: http and request.path == '/api/v1/users'
Related on TokRepo
- DevOps tools -- infrastructure and operations tooling for cloud-native workflows
- Monitoring tools -- observability and monitoring solutions
Common pitfalls
- Kubeshark requires privileged DaemonSet pods with host network access; some managed Kubernetes providers restrict this by default.
- On high-traffic clusters, capturing all traffic can generate significant data volume -- use KFL filters or namespace scoping to reduce noise.
- eBPF-based capture requires a Linux kernel 4.16 or later; older kernels fall back to raw socket capture with reduced protocol support.
Frequently Asked Questions
No. Kubeshark operates independently of any service mesh. It captures traffic at the node level using eBPF and raw sockets, so you do not need Istio, Linkerd, or any sidecar proxy installed.
Kubeshark decodes HTTP/1.1, HTTP/2, gRPC, Kafka, Redis, AMQP, MongoDB wire protocol, DNS, and raw TCP. New protocol decoders can be added through the extension system.
Yes, but with care. Kubeshark captures traffic at the node level, which has minimal performance overhead. However, on very high-traffic clusters you should scope capture to specific namespaces or pod patterns to limit resource usage.
KFL (Kubeshark Filter Language) lets you filter captured traffic in real time using expressions like 'http and request.path contains /api'. It supports logical operators, field comparisons, and regex matching.
Yes. Kubeshark can record traffic to PCAP files that you can open in Wireshark or other network analysis tools for detailed offline investigation.
Citations (3)
- Kubeshark GitHub— Kubeshark is an eBPF-powered API traffic viewer for Kubernetes
- Kubeshark Documentation— Decodes HTTP, gRPC, Kafka, Redis, AMQP, DNS protocols
- eBPF Foundation— eBPF for kernel-level network observability
Related on TokRepo
Discussion
Related Assets
NAPI-RS — Build Node.js Native Addons in Rust
Write high-performance Node.js native modules in Rust with automatic TypeScript type generation and cross-platform prebuilt binaries.
Mamba — Fast Cross-Platform Package Manager
A drop-in conda replacement written in C++ that resolves environments in seconds instead of minutes.
Plasmo — The Browser Extension Framework
Build, test, and publish browser extensions for Chrome, Firefox, and Edge using React or Vue with hot-reload and automatic manifest generation.