How do Minecraft Comparators Work?

Featured Image credit: Mojang.

Getting into redstone in Minecraft can sometimes seem almost impossible to understand, and nothing wants to work. 

Whileredstone can be used for amazing builds, all of those complex creations rely on the basics of each redstone device.

One of the most powerful and commonly used redstone devices is the comparator.

Outside the Minecraft world, a comparator receives an electrical signal. It then does something to it.

Fx, it can receive two analog electrical signals (e.g., from microphones) and turn them into a digital signal (like the analog-to-digital converter in your computer sound card), so you can voice chat while gaming.

Similarly, the Redstone comparator in Minecraft receives an electrical Redstone signal in the back input. This is then measured against a power source from two side sources, and an output signal is spat out at the front (marked by an arrow at the top).

So, essentially, a comparator compares the electrical signal of a main input to a secondary input. The different signal strengths and the function you choose determine the comparator’s output.

Depending on your setup, the comparator can do one of four things:

  • maintain the signal strength input (in = out)
  • compare the signal strength (measures the rear input, compares it to the two side inputs, and determines if the comparator should turn off or not – if the signal to a side input is stronger than the rear input, the comparator turns off).
  • subtract from the signal strength (the strongest side source signal is subtracted from the rear input signal)
  • measure block states (fx the fullness of containers).

I’ll explain these in more detail in this article.

Redstone comparators are used to build Redstone circuits which can be used for stuff like logic circuits, password circuits, creating a hopper clock, item sorters, sculk sensors, and more.

While most basic redstone builds do not use it, you can begin transforming your Minecraft world by learning how it works. 

Keep reading to see how to craft the comparator and use it to create complex redstone builds to dominate your world!  

Speaking of red blocks… check out this guide on how to make red nether bricks.

Crafting the Minecraft Comparator

Before you can use the comparator, you must craft it first. Unfortunately, you will have to visit the Nether to make this device. No building complex redstone before braving the depths of Hell. 

To make the comparator, you need the following:

  • 3 Redstone Torches
  • 1 Nether Quartz
  • 3 Stone Blocks

Quick Tip: Redstone torches are created by combining one redstone dust and one stick. If you do not know how to get stone blocks, you can make them by smelting cobblestone in a furnace.

Follow the Minecraft comparator crafting recipe below to create your own:

1. Open your crafting table.

Open the crafting table, and make sure you have 3 redstone torches, 1 nether quartz, and 3 stone blocks ready.

This content was first published on GameDaft.com

Comparator Minecraft ingredients
(Image credit: Mojang)

2. Place the three stone blocks in the bottom three slots.

Minecraft Comparator crafting recipe - place 3 stone blocks
(Image credit: Mojang)

3. Put the Nether Quartz in the middle slot.

Minecraft Comparator crafting recipe part 3 - place the quartz
(Image credit: Mojang)

4. Surround the Quartz with the three redstone torches, as shown below.

Minecraft Comparator crafting recipe part 4 - place the 3 redstone torches
(Image credit: Mojang)

5. Take the comparator and place it in your inventory. 

Minecraft Comparator crafting recipe part 5 - move it to the inventory
(Image credit: Mojang)

You now have the comparator, and now comes the difficult part, learning how to use it properly. 

Understanding How Minecraft Comparators work

If you have been dreading this part, don’t worry. While redstone and comparators can seem scary, they are quite easy to use once you learn their basics.

The Basics

When working with the comparator, you need to know its basic rules and the three modes you can put it into. 

How Minecraft comparators work guide part 1 - the basics
Here you can see I have placed down the comparator, and the output side is facing away from me.
(Image credit: Mojang)

Starting off, when you place a comparator down on the ground, the input is the side facing the player, and the output is the side facing away from the player.

Basically, the single torch in the front represents the output side and will always face away from the player. 

Now that you have the comparator placed, it can accept input from any of the three other sides, not the bottom or top. 

For a signal to move through a comparator, it takes one Redstone tick (one-tenth of a second), meaning any output will be one-tenth of a second slower than the input.

With the basics out of the way, it is time to use the comparator.

As I mentioned in the introduction, the comparator has four modes: maintain, comparison, subtraction, and block state detector.

Since the first state is self-explanatory (the strength of the input signals going in equals what comes out), I’ll focus on the latter three below.

Comparison Mode

Comparison mode is the base mode of comparators when they are placed down.

To toggle a comparator into comparison mode, right-click it until the front torch is down and turned off.

Minecraft comparators comparison mode example
Here I have a comparator taking two inputs from levers. Since their strength (5 + 4) is less than the torch (15), the comparator outputs a signal strength of 15, activating the piston.
(Image credit: Mojang)

In this state, the comparator compares its inputs to decide its output. It does this by looking at the total strength from the side and rear inputs.

Quick Tip: Redstone strength starts at 15 and decreases for every block away from the source of redstone power. 

If the rear input is equal to or less than the strength of both side inputs, then the comparator will output no signal (switch off). 

But if the rear signal is stronger than the side inputs, it will output the rear signal’s strength forward. 

Subtraction Mode

Minecraft Comparator substraction mode example
(Image credit: Mojang)

In subtraction mode, the comparator subtracts the signal strength of the lever from the redstone torch, meaning the piston is not activated.

The second mode of the comparator is the subtraction mode. In this mode, the comparator compares the strength of its inputs like in comparison mode. 

However, instead of outputting the rear’s input if it is stronger, it subtracts the strength of the highest side input from the rear input. 

It will then output the strength of that input. So, for example, you have two side inputs and a rear input. 

The two side inputs have strengths of 7 and 5, and the rear input has a strength of 15. In subtract mode, the comparator will take 15 – 7 and output a signal with a strength of 8.

Block State Detector

Block state detector is by far the most complicated aspect of comparators, but it can be used for some great redstone builds. 

To use a comparator as a block state detector, it must be in comparison mode, with the block whose state you are detecting placed in the rear. 

Minecraft comparator full chest block state detection
Here, I’ve filled a chest with stuff. Measuring this using the comparator gives me a strong signal I can use to drive a piston or sticky piston.
(Image credit: Mojang)

The basics of this concept are that a comparator will check a block, like a chest, to see how many full stacks it has and then output a signal based on that.

Minecraft comparator drives piston
Since the chest is fully filled, it outputs a signal strength strong enough to activate the piston.
(Image credit: Mojang)

The formula for the signal strength outputted is the number of full stacks/number of slots available * 15. 

Comparators can detect the state of all the following blocks:

  • Furnace
  • Blast Furnace
  • Hopper
  • Chest
  • Trapped Chest
  • Smoker
  • Dropper
  • Hopper Minecraft
  • Brewing Stand
  • Dispenser
  • Chest Minecart
  • Large Chest
  • Shulker Box
  • Large Trapped Chest
  • Barrel

These are all the main blocks that comparators can detect the fullness of.

Additionally, there are some special blocks that comparators can use. 

These include:

  • Ender Portal Frame: If an Eye of Ender is present, the comparator outputs a signal strength of 15. Otherwise, it is 0.
  • Beehive / Bee Nests: Equal to the amount of honey in the hive for a max signal strength of 5. 
  • Cauldron: Outputs a max signal strength of 3 when filled.
  • Jukebox: The signal strength depends on the music disc being played with a max of 13 when Pigstep is playing. 
  • Composter: Has a max signal strength output of 8 when filled.
  • Respawn Anchor: Dependent on the charge level of the respawn anchor for a max signal strength of 15 when fully charged. 
  • Command Block: Outputs a signal with a strength equal to the number of successful commands it runs. 
  • Lectern: The output signal strength depends on what page of the book the player is reading on the lectern. Fx, if the book has five pages, each page has a signal strength of 3. 
  • Item Frame: Item frames output a signal strength based on how many times the item within it has been rotated 45 degrees for a max signal strength of 8.

Conclusion

While redstone components can seem like a complicated aspect of Minecraft, by learning how the different pieces, like comparators, work, you can become a redstone master in no time.

If you found this article helpful, check out how to find mushrooms in Minecraft and get all the mushroom stew you could ever want. Until next time, happy gaming!


Profile picture

ABOUT THE AUTHOR:

Jan has played video games since the early 1980s. He loves getting immersed in video games as a way to take his mind off stuff when the outside world gets too scary. A lifelong gamer, the big interest led to a job as a lecturer on game sound at the University of Copenhagen and several written articles on video games for magazines.

Read more on the About Page.