Item Counter Doorway

This item counter doorway requires players to deposit five specific items into a hopper before unlocking an iron door. As each item is added, a row of five Redstone lamps lights up one by one to show progress, and a built-in item filter prevents random items from jamming the system. It is ideal for adventure maps, puzzle rooms, or toll gates where players must collect a set number of tokens to proceed.

Item CircuitsIntermediateJava Edition
Item Counter Doorway video tutorial

Video: Item Counter Doorway -- Super Minecraft Maker Redstone Tutorial by SethBling

How to build it

  1. Place the Input Stack and Lamps

    At floor level, place a hopper feeding downward into a dropper, and put a second hopper directly underneath that dropper to catch drained items. In the floor nearby, place a row of five Redstone lamps to serve as your progress indicator.

  2. Wire the Filter Threshold Reader

    Place a Redstone comparator reading the middle dropper and run two Redstone dust from its output. Attach a Redstone torch to the side of the block carrying the second dust so that the torch sits adjacent to the bottom hopper, locking it by default.

  3. Load the Item Filter

    Open the middle dropper and place 33 of your target 64-stackable item (such as emeralds) in the first slot, and 1 of that same item in each of the remaining 8 slots (41 items total). This fills every slot for filtering and sets the comparator right at the edge of signal strength 1.

  4. Install the Sticky Piston Pulse Gate

    Next to the Redstone torch under the dropper, place an upward-facing sticky piston with a solid block on its face. When the torch briefly turns off, the piston will retract the solid block for a moment.

  5. Set Up the Subtraction Pulse Generator

    Place a second dropper containing a single item of any kind so a comparator can read it into the position where the sticky piston's block sits when retracted. On the output side of that block position, place one Redstone dust leading directly into the side of the memory cell comparator.

  6. Build the Analog Memory Loop

    Construct a comparator loop that preserves signal strength by placing two comparators facing opposite directions and connecting their inputs and outputs with Redstone dust loops. Right-click the comparator receiving the side input from the piston gate to put it into subtraction mode (front torch lit).

  7. Run the Main Signal Line

    From the output of the comparator memory loop, run a line of Redstone dust over to your row of five Redstone lamps and extend it five blocks parallel to the lamps. The reach of the signal along this five-block line will shrink by one block each time an item is counted.

  8. Build the Lamp Inverter Towers

    Point five Redstone repeaters out from the five-block dust line toward the lamps, running each into a solid block with a Redstone torch on top to invert the signal. Place solid blocks next to those torches and run a second row of five repeaters from them directly into the five Redstone lamps.

  9. Add the Reset Button

    Place a button along the Redstone dust line leading between the memory loop and the five repeaters so that pressing it feeds a signal strength back into the loop that leaves the furthest repeater at signal strength 1. Pressing this button will reset all five lamps to off.

  10. Wire the Iron Door and Cover the Floor

    From the inverter line of the fifth lamp, branch off to power a Redstone torch underneath a solid block and place an iron door on top in a sideways orientation so it stays closed while the torch is on and swings open when the fifth lamp lights up. Cover the floor and exposed repeaters with solid blocks and carpet.

How it works

This circuit combines an item filter threshold detector with a decrementing analog memory cell:

  • Item Filtering and Threshold Detection: The input dropper is pre-loaded with 33 target items in the first slot and 1 in each of the other eight slots (41 total for 64-stackable items). Because all 9 slots are occupied, the input hopper can only push matching items into the dropper; any wrong item stays safely in the top hopper. At 41 items, the comparator outputs signal strength 1. The moment a 42nd item enters, the signal strength jumps to 2.
  • Self-Draining Pulse: When the comparator output hits strength 2, the second piece of Redstone dust turns on and powers the block holding the Redstone torch. The torch turns off briefly, doing two things at once: it unlocks the bottom hopper to pull the extra item out of the dropper (returning the dropper to 41 items), and it de-powers the sticky piston.
  • Analog Subtraction Memory: When the sticky piston retracts its block for a single pulse, a comparator reading a dropper with 1 item sends a signal strength of 1 through the block into the side of a subtraction-mode comparator in the memory loop. Two comparators feeding into each other act as an analog latch that remembers its current power level. Each item deposited subtracts 1 from the stored signal strength.
  • Lamp Bar and Door Trigger: When reset, the memory loop holds just enough signal strength to reach all five repeaters along the output line (with the furthest at strength 1). The repeaters power Redstone torches, holding them off. Each time an item subtracts 1 from the loop, the signal falls one block shorter, turning off one repeater, lighting its inverting torch, and powering the corresponding Redstone lamp. When the fifth item is inserted, the final inverter also turns off a torch beneath the sideways-placed iron door, allowing it to open.

Tips & variations

  • Stack-Drop Safe: Because the bottom hopper drains items one at a time and the comparator re-triggers the torch for every item until the dropper returns to 41 items, players can shift-click a stack or drop multiple items at once and the torch will pulse once per item.
  • Recovering Extra Items: The bottom hopper simply collects the counted items. You can empty it manually or hook it up to a storage chest or return line without affecting the counter's state.
  • Changing the Target Item Count: You can build this for more or fewer items by adding or removing lamps and inverter lanes, then adjusting the placement of the reset button along the Redstone line so that the furthest repeater always starts at signal strength 1.
  • Sideways Door Placement: Because the door is controlled by an inverting torch, place the iron door while facing sideways into the doorway frame so that its powered state keeps the doorway blocked and its unpowered state opens the path.

Frequently asked questions

What happens if a player puts the wrong item into the hopper?
Because all nine slots of the middle dropper are already filled with the target item, the top hopper cannot push any other item type into it. The wrong item simply waits in the top hopper where the player can take it back.
Can players put all five items into the hopper at the same time?
Yes. If you shift-click multiple target items in at once, the torch and sticky piston will blink once for each item as the bottom hopper drains them, stepping the counter down accurately.
How do you reset the doorway after it opens?
Press the reset button wired into the Redstone dust line between the comparator memory loop and the repeaters. It restores the stored signal strength in the comparator loop, turning off all five lamps and closing the door.

Components used

More item counter