Set up Kafka for development

Get a local Kafka cluster running for development — Docker, native macOS, Linux, Windows, or a Conduktor hosted Kafka cluster. Pick your setup and start.

Get your first Kafka cluster running

This section guides you through setting up Apache Kafka for development and learning. Choose from multiple installation options based on your operating system and preferences.

What you'll learn:

  • How to set up a Kafka cluster for development
  • Different installation methods and their trade-offs
  • How to verify your Kafka installation

Prerequisites:

  • Basic command line knowledge
  • Java 11+ installed (for local installations)
  • Docker installed (for container-based setup)

Choose your setup method

Kafka setup decision tree: choose Docker Compose if you have Docker, otherwise pick by OS — Homebrew or native on Mac, native on Linux, WSL2 plus native on Windows

Installation options

MethodBest forTimeRequirements
Docker ComposeCross-platform, version switching5 minDocker
Mac nativemacOS development15 minJava 11
Mac HomebrewQuick Mac setup10 minHomebrew
Linux nativeLinux development15 minJava 11
Windows WSL2Windows development20 minWSL2, Java 11

Which method should I choose?

For most users, Docker Compose is the best choice. It works on all operating systems, makes version switching straightforward, and keeps your system clean. Use native installation if you need direct access to Kafka binaries or prefer not to use Docker.

ZooKeeper vs KRaft mode

Kafka traditionally requires ZooKeeper for cluster coordination. Starting with Kafka 2.8, KRaft mode allows Kafka to run without ZooKeeper.

ModeStatusRecommendation
ZooKeeperStable, production-readyUse for learning and production
KRaftProduction-ready (Kafka 3.3+)Use for simplified deployments
KRaft installation guides:

See it in practice with Conduktor

Conduktor Console provides a visual interface for connecting to and managing your Kafka clusters once they're running.

Next steps