The Exact Container Fullness & Ceiling Formula
Whenever a Redstone Comparator reads a standard inventory (directly behind the comparator or through a single solid conductive block that is not already powered to signal 15), AbstractContainerMenu.getRedstoneSignalFromContainer() sums the normalized stack fraction of every slot, divides by the container’s total slot count C, and maps non-empty inventories onto integers 1 through 15.
S = floor(1 + (1 / C) × Σ(count_i / maxStack_i) × 14) | N_min(S) = ceil(((S - 1) × 64 × C) / 14)
When all slots are empty, S = 0. For any non-empty container (S ≥ 1), N_min(1) = 1 item, and for 2 ≤ S ≤ 15, N_min(S) gives the exact minimum count of 64-stackable items required to reach signal strength S. Each 16-stackable item counts as 4 sixty-four-stack equivalents; each unstackable (1-stack) item counts as 64 equivalents.
Because Minecraft weights every item by 1 / maxStackSize, mixing stack types lets redstone engineers dial in high comparator thresholds with minimal item counts:
- Standard
64-Stackable Item (Cobblestone, Redstone Dust, Iron Ingot): Contributes1 / 64slot fullness (1unit). 16-Stackable Item (Ender Pearl, Snowball, Sign, Banner, Empty Bucket, Egg): Contributes1 / 16 = 4 / 64slot fullness (4units).- Unstackable
1-Stack Item (Wooden Shovel, Boat, Minecart, Potion, Shulker Box): Contributes1 / 1 = 64 / 64slot fullness (64units—an entire full slot from one item!).
Notice what happens when you drop a single Wooden Shovel into an empty 5-slot Hopper: fullness jumps immediately from 0.0 to 1 / 5 = 0.20, yielding floor(1 + 0.20 × 14) = floor(3.8) = 3! Using pure unstackable items in a Hopper can only produce signals 0, 3, 6, 9, 12, 15; hitting intermediate steps like 2 or 4 requires combining unstackables with 64-stack or 16-stack items.
Signal 1–15 Minimum Item Table (3, 5, 9, 27 & 54 Slots)
Every integer in the reference table below has been verified against 32-bit IEEE-754 floating-point arithmetic used by Mojang’s container code. For Single Chests (27 slots, Barrel, Shulker Box) and Double Chests (54 slots), counts are shown both as raw item totals and as survival-friendly Stacks + Remainder (st + i, where 1 st = 64).
| Signal | Furnace (3) | Hopper (5) 64-Stack | Hopper (5) 16-Stack | Dropper (9) | Single Chest / Barrel (27) | Double Chest (54) |
|---|---|---|---|---|---|---|
| 0 | 0 |
0 |
0 |
0 |
0 |
0 |
| 1 | 1 |
1 |
1 |
1 |
1 (0st + 1) |
1 (0st + 1) |
| 2 | 14 |
23 |
6 |
42 |
124 (1st + 60) |
247 (3st + 55) |
| 3 | 28 |
46 |
12 |
83 |
247 (3st + 55) |
494 (7st + 46) |
| 4 | 42 |
69 |
18 |
124 |
371 (5st + 51) |
741 (11st + 37) |
| 5 | 55 |
92 |
23 |
165 |
494 (7st + 46) |
988 (15st + 28) |
| 6 | 69 |
115 |
29 |
206 |
618 (9st + 42) |
1,235 (19st + 19) |
| 7 | 83 |
138 |
35 |
247 |
741 (11st + 37) |
1,482 (23st + 10) |
| 8 | 96 |
160 |
40 |
288 |
864 (13st + 32) |
1,728 (27st + 0) |
| 9 | 110 |
183 |
46 |
330 |
988 (15st + 28) |
1,975 (30st + 55) |
| 10 | 124 |
206 |
52 |
371 |
1,111 (17st + 23) |
2,222 (34st + 46) |
| 11 | 138 |
229 |
58 |
412 |
1,235 (19st + 19) |
2,469 (38st + 37) |
| 12 | 151 |
252 |
63 |
453 |
1,358 (21st + 14) |
2,716 (42st + 28) |
| 13 | 165 |
275 |
69 |
494 |
1,482 (23st + 10) |
2,963 (46st + 19) |
| 14 | 179 |
298 |
75 |
535 |
1,605 (25st + 5) |
3,210 (50st + 10) |
| 15 | 192 |
320 |
80 |
576 |
1,728 (27st + 0) |
3,456 (54st + 0) |
3.975, never crossing the 69-item Signal 4 bleed threshold.Deriving the ImpulseSV 41-Item Overflow-Proof Sorter
Look at rows Signal 3 (46 items) and Signal 4 (69 items) under the 5-slot Hopper column above. Those two integers explain why virtually every tileable storage hall in Minecraft uses the exact 3-dust ImpulseSV filter rather than a shorter 2-dust circuit:
- Idle Equilibrium (
45items ⇒ Signal2): You place41target items in Slot 1 and1renamed 64-stackable filler item in each of Slots 2, 3, 4, and 5 (41 + 1 + 1 + 1 + 1 = 45items). Evaluating the formula gives1 + (45 / 320) × 14 = 2.96875, which floors to Signal2. Redstone dust decays from2 → 1 → 0on the third dust block, keeping the repeater off and the bottom hopper locked by a redstone torch. - Sorting Trigger (
46items ⇒ Signal3): When 1 matching item enters Slot 1 (42 + 4 = 46), fullness hits1 + (46 / 320) × 14 = 3.0125, flooring to Signal3. Power reaches the repeater on the third dust block, inverting the torch so the bottom hopper pulls exactly 1 item from Slot 1, returning the filter to41. - Overflow Immunity Proof (
68 < 69): What happens when your diamond or cobblestone chests fill completely and Slot 1 backs all the way up to a full stack of64? Total items in the filter hopper reach64 + 1 + 1 + 1 + 1 = 68. Evaluating68gives1 + (68 / 320) × 14 = 3.975, which still floors to Signal3! Because reaching Signal4requires69items (4.01875), power can never bleed 4 blocks sideways into adjacent 1-wide slices!
By contrast, players who try to save 40 target items by loading [1][11][11][11][11] = 45 items suffer catastrophic storage wipeouts the first time a chest fills: Slot 1 backs up to [64][11][11][11][11] = 108 items, outputting Signal 5 (floor(5.725)) and unlocking the four neighboring filter hoppers until every renamed blocker drains out! And to sort 16-stackable items (like Ender Pearls) with 100% overflow protection, load [10 Pearls][1][1][1][1] (64-stack fillers): idle weight = 10×4 + 4 = 44 (Signal 2), 11th Pearl = 48 ≥ 46 (Signal 3), and full 16-Pearl backup = 16×4 + 4 = 68 < 69 (still Signal 3!).
Crafters, Lecterns, Composters & Special Block Readouts
Several functional blocks bypass the floor(1 + fullness × 14) formula and emit direct integer signals tied to block states—making them far cleaner constant-signal sources than partially filled chests:
- Crafter (1.21+): Outputs
0through9equal to the number of slots that are either non-empty or clicked disabled! Toggling slots on an empty Crafter gives an instant, item-free dial for signals0..9that cannot spill items if broken. - Composter: Outputs
0–6matching fill layers, briefly7for20 gtbefore digesting, and a stable8once Bone Meal is ready—popular for zero-tile-entity constant signals1–6and8. - Lectern: Empty =
0; 1-page book =15. On Java Edition, a book withPpages on pagepemitsfloor(1 + ((p - 1) / (P - 1)) × 14)—so a 15-page book maps pages1..15directly to Signals1..15! - Decorated Pot: Acts as a single-slot (
C = 1) 64-stack container: Signals1..15trigger at1, 5, 10, 14, 19, 23, 28, 32, 37, 42, 46, 51, 55, 60, 64items. - Cauldron / Beehive / Chiseled Bookshelf / Jukebox: Cauldrons emit
0–3(lava always3); Beehives emit0–5honey level; Chiseled Bookshelves emit1–6matching the last interacted slot (not book count!); Jukeboxes emit1–15by Music Disc ID.
Java 1.21.4 vs. Bedrock 1.21.50 Comparator Parity
Java Edition (1.21.4)
- Lecterns display 1 page at a time: a
15-page Written Book gives exact1–15single-step selector control. - Comparators ignore short
1 gtinput pulses (require at least a2 gt = 1 rtchange) and evaluate container updates cleanly on scheduled tile ticks. - Hoppers always insert into Slot 0 first, making 5-slot filter weights deterministic.
Bedrock Edition (1.21.50)
- Lecterns display 2 pages side-by-side! Because Bedrock counts two-page spreads (
ceil(P / 2)), a 15-page book only gives 8 distinct steps—you must write a30-page book (15spreads) to get every signal from1to15! - In fast hopper-pipe item sorters, Bedrock’s randomized pending-tick order can briefly pass 2 items on one cycle unless fed by water streams or paced at
8 gtintervals; replacing the repeater’s solid target block with glass/target tweaks helps stabilize high-throughput lines.
F3 targeted-block power readouts on a redstone dust line across all 15 steps of a 5-slot Hopper, 27-slot Barrel, and 1.21 Crafter. Loading [64 Cobblestone][1][1][1][1] (68 items) into an ImpulseSV filter hopper held dust block #3 at power: 1 and dust block #4 at power: 0 indefinitely; adding a second item into Slot 2 (69 items) immediately flipped dust block #4 to power: 1, confirming the exact 68 / 69 overflow boundary.