The high water mark (HWM) is the boundary between replicated, committed records and records still awaiting replication in a Kafka partition. Consumers can read only through this boundary, so a newly produced record may briefly exist beyond the HWM before becoming available. section 8.4.2 section 8.5
The leader calculates the HWM from replica progress. Each leader and follower advances its Log End Offset (LEO); the HWM corresponds to the smallest committed LEO among the in-sync replicas (ISRs). The leader shares this position with followers during fetches. section 8.4.2
A record moves toward consumer visibility through this flow:
- The partition leader receives the record and advances its LEO. section 8.4.2
- Followers fetch missing records and report their current LEO to the leader. section 8.4.2
- After the required ISRs have received the record, the HWM advances and consumers can read it. section 8.4.2
When a replica falls behind
Suppose an ISR can no longer replicate quickly enough. While it remains in the ISR set, it holds the HWM back and slows or blocks near-real-time consumption. Once it exceeds the configured maximum lag and leaves the ISR set, the HWM may jump forward. If fewer replicas than min.insync.replicas remain in sync, the HWM stops advancing, so consumers cannot read new records; producers using acks=all also cannot publish. section 8.4.3
Figure 8.5 The High Watermark is the offset that all ISRs have replicated and committed to the leader. The lowest follower isn’t in sync and isn’t taken into account when calculating the HWM.
Visualizes the HWM as the offset replicated by all relevant ISRs while excluding a follower that is no longer in sync. section 8.4.2

