whatisgithub

What is flannel?

flannel-io/flannel — explained in plain English

Analysis updated 2026-06-24

9,451GoAudience · ops devopsComplexity · 4/5LicenseSetup · hard

In one sentence

Flannel is a networking layer for Kubernetes that gives every container its own IP address so containers on different servers can talk to each other directly, with no port-mapping complexity.

Mindmap

mindmap
  root((repo))
    What it does
      Container IP assignment
      Cross-node routing
      VXLAN wrapping
    Deployment
      kubectl one command
      Helm chart
      K3s built-in
    Config storage
      Kubernetes API
      etcd alternative
    Limitations
      No network policy
      Add Calico for policy
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Deploy flannel to a bare Kubernetes cluster so containers on different nodes can reach each other using direct IP addresses.

USE CASE 2

Use flannel as the built-in network plugin when setting up a lightweight Kubernetes distribution like K3s, it is often included automatically.

USE CASE 3

Add container networking to a Docker setup that runs without Kubernetes by pairing flannel with etcd as the configuration store.

What is it built with?

GoKubernetesVXLANetcdHelm

How does it compare?

flannel-io/flannelsjwhitworth/golearngoplus/xgo
Stars9,4519,4449,417
LanguageGoGoGo
Setup difficultyhardeasymoderate
Complexity4/52/53/5
Audienceops devopsdeveloperdeveloper

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · hard Time to first run · 1h+

Requires a running Kubernetes cluster, flannel handles only pod-to-pod traffic routing and needs a separate tool like Calico if you need network policy enforcement.

Apache 2.0: use freely for any purpose including commercial products, as long as you include the copyright and license notice.

So what is it?

Flannel is a networking tool designed for Kubernetes, the system many companies use to run and manage large numbers of containers across multiple servers. The core problem it solves is giving each container its own unique IP address on the network, so containers can talk to each other directly without the complexity of mapping ports on a shared server address. The way flannel works is by running a small background program called flanneld on each server (called a node) in the cluster. Each node gets assigned its own private block of IP addresses. When a container on one node wants to send data to a container on another node, flannel handles the translation and forwarding. It uses a technique called VXLAN by default, which wraps the traffic in an outer layer so it can travel across the physical network between servers. The network configuration is stored either in the Kubernetes API itself or in a separate key-value store called etcd. Flannel only handles the traffic-between-servers part of networking. It does not control policies about which containers are allowed to talk to which, that is left to other tools. The README notes that projects like Calico can be layered on top if network policy enforcement is needed. Deploying flannel on a Kubernetes cluster can be done with a single command using kubectl, or through Helm (a Kubernetes package manager). It is also commonly included automatically in lightweight Kubernetes distributions like K3s, so many users get it without any manual setup. It can also be used outside of Kubernetes alongside Docker, in which case it requires etcd as the configuration store. Flannel is written in Go and licensed under the Apache 2.0 license. The project has a public Slack community, holds monthly maintainer meetings, and publishes a roadmap on GitHub.

Copy-paste prompts

Prompt 1
Give me the kubectl command to deploy flannel with VXLAN mode to a new Kubernetes cluster and verify it is working.
Prompt 2
Pods on different nodes in my Kubernetes cluster cannot reach each other. Help me debug whether flannel is correctly installed and routing traffic.
Prompt 3
How do I install flannel using Helm and configure it to use a custom pod CIDR range like 192.168.0.0/16?
Prompt 4
I need network policy enforcement on top of flannel. Walk me through layering Calico onto an existing flannel-based cluster.

Frequently asked questions

What is flannel?

Flannel is a networking layer for Kubernetes that gives every container its own IP address so containers on different servers can talk to each other directly, with no port-mapping complexity.

What language is flannel written in?

Mainly Go. The stack also includes Go, Kubernetes, VXLAN.

What license does flannel use?

Apache 2.0: use freely for any purpose including commercial products, as long as you include the copyright and license notice.

How hard is flannel to set up?

Setup difficulty is rated hard, with roughly 1h+ to a first successful run.

Who is flannel for?

Mainly ops devops.

Open on GitHub → Ask about another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.