Set up and Install Apache Kafka On Windows

Prerequisites: Install Java

Step 1:

Download the kafka from

Extract the downloaded file using 7 zip

Step 2:

Kafka uses zookeeper so you first need to start the ZooKeeper Server, zookeeper is packaged with kafka

Run the below command to start zookeeper

.\bin\windows\zookeeper-server-start.bat .\config\

Once the ZooKeeper starts, run the kafka instance using below command

Step 3:

.\bin\windows\kafka-server-start.bat .\config\

Server started:

Installation is completed for kafka now you can create topic to publish the message in Kafka

Step 4:

Command to create the topic

kafka-topics.bat –create –bootstrap-server localhost:9092 –replication-factor 1 –partitions 1 –topic test

you can verify if the topic has created successfully in kafka instance using below command

kafka-topics.bat –list –bootstrap-server localhost:9092

you can see topic name test is created in kafka

Note:Zookeeper runs on 2181 and Kafka run on 9092 default port number

Thank you for taking out time to read the above post. Hope you found it useful. In case of any questions, feel free to comment below. Also, if you are keen on knowing about a specific topic, happy to explore your recommendations as well.
For any latest updates or posts on our website, you can follow us on LinkedIn. Look forward to connecting with you there.

Share this:
Notify of
Inline Feedbacks
View all comments