---
title: "KIP-480 and KIP-794 explained: the sticky partitioner"
description: "KIP-480 and KIP-794 in plain words: how the Kafka producer picks a partition for records without a key, why it sticks to one, and the 3.3 uniform rewrite."
url: https://monedula.dev/kafka/kips/kip-480/
---

# KIP-480: the sticky partitioner for records without a key

Producers and transactions · Shipped · since Kafka 2.4 · status checked November 2026.

KIP-480 changed where the Kafka producer sends records without a key. Instead of spreading them round-robin, one record per partition, it sticks to one partition until a batch is full and then moves on, which makes bigger batches and lower latency. KIP-794 in Kafka 3.3 fixed its flaw: switching after a fixed number of bytes, so slow brokers no longer attract more data.

## At a glance

- Proposal: KIP-480, Sticky Partitioner
- Status: Shipped. Since Kafka 2.4 (2019); replaced by the strictly uniform version of KIP-794 in 3.3.
- Area: Producers and transactions
- Proposal page: [KIP-480 on the Apache Kafka wiki](https://cwiki.apache.org/confluence/display/KAFKA/KIP-480%3A+Sticky+Partitioner)

## Why it was needed

Round-robin sounds fair, but it splits a burst of keyless records across every partition, so each batch is tiny and the producer sends many small requests. With linger.ms at 0 that cost throughput and latency on every busy producer.

## What it changes

Since KIP-480 (Kafka 2.4) the producer picks a sticky partition for keyless records and keeps it until a new batch starts. That created a feedback loop: a partition on a slow broker filled batches slowly, stayed sticky longer and so received even more records. KIP-794 (Kafka 3.3) switches after batch.size bytes instead, and with adaptive partitioning, on by default, it sends less to partitions whose queues grow. Records with a key still go to the partition their key hashes to.

## How to use it

- Leave partitioner.class unset: the built-in logic is the KIP-794 one.
- partitioner.adaptive.partitioning.enable (default true) and partitioner.availability.timeout.ms (default 0, off) tune how it avoids slow brokers.
- partitioner.ignore.keys=true spreads keyed records like keyless ones, at the cost of per-key ordering.

## Where it stands

KIP-480 shipped in Kafka 2.4 and KIP-794 in Kafka 3.3. The old DefaultPartitioner and UniformStickyPartitioner classes, deprecated in 3.3, were removed in Kafka 4.0, so the built-in behaviour is now only reachable by leaving partitioner.class unset.

## What comes next

Kafka 4.4 added rack-aware partitioning (KIP-1123) on top, which limits the sticky choice to partitions led in the producer's own zone. A misspelled constant for the adaptive setting is deprecated and goes away in 5.0.

## See it in the simulator

- [Kafka producer partitioners: keyed, round-robin and sticky](https://monedula.dev/kafka-simulator/scenarios/producer-partitioners/) (Producer partitioners), step 4: Uniform-sticky: one partition per batch. No-key records stick to a single partition, then the sticky partition moves on for the next batch. In Kafka 4.x this is the default partitioner's keyless mode (KIP-794), which switches only after batch.size bytes, to a random load-weighted partition; the simulator switches per batch to make it visible. [Open at this step](https://monedula.dev/kafka-simulator/playground/?scenario=01.2.2&t=3)
- [Kafka producer partitioners: keyed, round-robin and sticky](https://monedula.dev/kafka-simulator/scenarios/producer-partitioners/) (Producer partitioners), step 3: Round-robin: even spread. No-key records cycle across all four partitions, one step per record - an even load spread. [Open at this step](https://monedula.dev/kafka-simulator/playground/?scenario=01.2.2&t=2)

## Sources

- [KIP-480: Sticky Partitioner](https://cwiki.apache.org/confluence/display/KAFKA/KIP-480%3A+Sticky+Partitioner)
- [KIP-794: Strictly Uniform Sticky Partitioner](https://cwiki.apache.org/confluence/display/KAFKA/KIP-794%3A+Strictly+Uniform+Sticky+Partitioner)
- [Apache Kafka 4.4 upgrade notes](https://kafka.apache.org/44/getting-started/upgrade/)

## Related KIPs

- [KIP-1123 explained: rack-aware producer partitioning](https://monedula.dev/kafka/kips/kip-1123/)
- [KIP-679 explained: acks=all and idempotence by default](https://monedula.dev/kafka/kips/kip-679/)
