---
title: "Kafka min.insync.replicas explained (with acks=all)"
description: "What Kafka min.insync.replicas does: the fewest in-sync replicas an acks=all write needs, why 2 with replication factor 3 is the norm, and NOT_ENOUGH_REPLICAS."
url: https://monedula.dev/kafka-simulator/configs/min-insync-replicas/
---

# min.insync.replicas: the floor for acks=all writes

Topic config · default 1 · Apache Kafka 4.3.

min.insync.replicas is the fewest in-sync replicas, leader included, that must have a write for an acks=all produce to succeed (default 1). When the ISR is smaller, the leader rejects acks=all writes with NOT_ENOUGH_REPLICAS. It has no effect on acks=0 or acks=1 producers, or on consumers.

## At a glance

- Config: `min.insync.replicas` (topic)
- Default: 1
- Valid values: 1 or more
- Also set at: Also a broker setting, min.insync.replicas, which is the default for topics that do not set it.
- Reference: [Apache Kafka documentation](https://kafka.apache.org/43/configuration/topic-configs/#topicconfigs_min.insync.replicas)

## What it does

An acks=all producer waits until every replica in the ISR has the record. On its own, that could mean only the leader if the followers have fallen out of the ISR. min.insync.replicas puts a floor under it: with the ISR below the floor, the leader refuses the write instead of accepting a record that would live on too few brokers. The error is retriable, so the producer keeps retrying until the ISR recovers or delivery.timeout.ms runs out.

## The trade-off

A higher value means every acknowledged record is on more brokers, but fewer brokers can be down before acks=all producers stop. With replication.factor=3, min.insync.replicas=2 tolerates one broker down for writes and guarantees two copies; 3 would block writes during any broker restart; 1 keeps writing with a single copy, so losing that broker loses data.

## Advice

- Use replication.factor=3 with min.insync.replicas=2 and acks=all as the baseline for data you cannot lose.
- Never set it equal to the replication factor: every rolling restart then blocks writes.
- Alert on under-min-ISR partitions; they are refusing writes from acks=all producers right now.

## See it in the simulator

- [min.insync.replicas with acks=all: when Kafka refuses writes](https://monedula.dev/kafka-simulator/scenarios/min-isr-boundary/) (min.ISR boundary), step 6: O3 blocked - NotEnoughReplicas. acks=all needs 2 in-sync replicas; only 1 remains. [Open at this step](https://monedula.dev/kafka-simulator/playground/?scenario=03.1.2&t=5)
- [Kafka acks=0 vs acks=1 vs acks=all on a degraded ISR](https://monedula.dev/kafka-simulator/scenarios/acks-tradeoff/) (acks trade-off), step 4: acks=all produce blocked - NotEnoughReplicas. Durability wins: acks=all refuses to ack below min.insync.replicas. [Open at this step](https://monedula.dev/kafka-simulator/playground/?scenario=01.1.3&t=3)

## Related configs

- [Kafka acks: 0 vs 1 vs all explained](https://monedula.dev/kafka-simulator/configs/acks/)
- [Kafka unclean.leader.election.enable: the data loss risk](https://monedula.dev/kafka-simulator/configs/unclean-leader-election-enable/)
- [Kafka enable.idempotence: no duplicates on retry](https://monedula.dev/kafka-simulator/configs/enable-idempotence/)
