# Set up Kafka for development

*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](https://www.conduktor.io/assets/kafka/diagrams/starting-kafka.svg)

```mermaid
flowchart TD
    A[Want to run Kafka?] --> B{Have Docker?}
    B -->|Yes| C[Docker Compose<br/>Recommended]
    B -->|No| D{Operating System?}
    D -->|Mac| E{Prefer Homebrew?}
    D -->|Linux| F[Native install]
    D -->|Windows| G[WSL2 + Native]
    E -->|Yes| H[Homebrew install]
    E -->|No| I[Native install]

    C --> J[Ready in 5 min]
    F --> J
    G --> J
    H --> J
    I --> J
```

## Installation options

| Method | Best for | Time | Requirements |
|--------|----------|------|--------------|
| [Docker Compose](https://www.conduktor.io/kafka/how-to-start-kafka-using-docker) | Cross-platform, version switching | 5 min | Docker |
| [Mac native](https://www.conduktor.io/kafka/how-to-install-apache-kafka-on-mac) | macOS development | 15 min | Java 11 |
| [Mac Homebrew](https://www.conduktor.io/kafka/how-to-install-apache-kafka-on-mac-with-homebrew) | Quick Mac setup | 10 min | Homebrew |
| [Linux native](https://www.conduktor.io/kafka/how-to-install-apache-kafka-on-linux) | Linux development | 15 min | Java 11 |
| [Windows WSL2](https://www.conduktor.io/kafka/how-to-install-apache-kafka-on-windows) | Windows development | 20 min | WSL2, 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.

| Mode | Status | Recommendation |
|------|--------|----------------|
| ZooKeeper | Stable, production-ready | Use for learning and production |
| KRaft | Production-ready (Kafka 3.3+) | Use for simplified deployments |

KRaft installation guides:
- [Mac KRaft](https://www.conduktor.io/kafka/how-to-install-apache-kafka-on-mac-without-zookeeper-kraft-mode)
- [Linux KRaft](https://www.conduktor.io/kafka/how-to-install-apache-kafka-on-linux-without-zookeeper-kraft-mode)
- [Windows KRaft](https://www.conduktor.io/kafka/how-to-install-apache-kafka-on-windows-without-zookeeper-kraft-mode)

> **See it in practice with Conduktor**
> [Conduktor Console](https://docs.conduktor.io/guide/conduktor-in-production/admin/configure-clusters) provides a visual interface for connecting to and managing your Kafka clusters once they're running.

## Next steps

- [Conduktor Console](https://www.conduktor.io/kafka/how-to-start-kafka-with-conduktor) for a hosted cluster with no local setup
- [Docker setup](https://www.conduktor.io/kafka/how-to-start-kafka-using-docker) for the fastest cross-platform local cluster
- [CLI tutorials](https://www.conduktor.io/kafka/kafka-cli-tutorial) to interact with your cluster once it's running
