Skip to content
LSLab

How Does CNOT Link Control and Target Qubits?

  • Basic
  • Article
  • Ages 14+
  • 6 min read
Two qubit structures on a chip connected by a metallic coupling trace.

The CNOT gate is a two-qubit gate: it leaves the target qubit alone or flips it, depending on the state of the control qubit. For computational-basis inputs, the target value is the XOR of the two input values. CNOT matters because, together with single-qubit gates, it is enough to build any multi-qubit gate.

Contents
The control qubit above acts on the target qubit below through a gate.
  • Control qubit
  • Target qubit with the gate's plus sign

What you will learn

  • Describe what CNOT does to the control qubit and the target qubit.
  • Explain why CNOT is treated as a building block of quantum circuits.
  • Tell a gate like CNOT apart from a measurement.

Before you start

It helps to read How Does a Qubit Differ from a Bit? first. Other terms are explained as they appear.

What does CNOT do to two qubits?

CNOT flips or keeps the target qubit, depending on the state of the control qubit. According to the Stanford Encyclopedia of Philosophy, it is the controlled-NOT gate and takes two qubits as input. It either flips or preserves its “target” input bit depending on the state of its “control” input bit.

More precisely, the output state of the target qubit is the result of an operation analogous to the classical exclusive-OR (XOR) gate on the inputs.

Think of two switches to understand the basis-state rule: control off preserves the target; control on flips it. The control is not read by a measurement. For a superposed control, CNOT acts on the joint state rather than first selecting a branch.

The basis-state rule preserves or flips the target according to the control; switches do not represent superposition.
  • Control off: target kept
  • Control on: target flipped

As Microsoft Learn explains, one way to create an entangled pair starts with both qubits in zero, applies Hadamard to superpose the control, then applies CNOT. The output is a superposition of “both zero” and “both one”. CNOT preserves the quantum relationship between branches, which two classical switches cannot describe. By contrast, a definite “both zero” input stays unchanged under CNOT alone; CNOT does not always create entanglement.

Why is CNOT treated as a building block?

Because CNOT and single-qubit gates are enough to build any multi-qubit gate. According to the Stanford source, any multiple-qubit logic gate may be composed from a combination of single-qubit gates and the two-qubit controlled-not gate.

The Stanford source adds a related result: DiVincenzo showed in 1995 that two-qubit gates are sufficient to realise any quantum circuit.

On the experimental side, the Stanford source records that the first experimental realisation of the quantum CNOT gate with trapped ions was proposed by Cirac and Zoller in 1995.

Single-qubit gates and CNOT combine into a larger gate.
  • Single-qubit gates (squares)
  • CNOT gate (circle with a plus sign)
  • The composed multi-qubit gate

How does CNOT differ from a measurement?

CNOT is reversible and a measurement is not. According to the Stanford source, a general feature of quantum gates is that they are always reversible: a quantum gate can always be inverted by another quantum gate.

A measurement is different. To read the result of a computation, the quantum register must be measured. The Stanford source describes measurement as a non-unitary gate that “collapses” the superposition in the register onto one of its terms.

Classical gates differ too: they are Boolean logic gates that manipulate information stored in bits. In quantum computing, gates are represented by matrices.

A gate can go both ways, while a measurement goes one way only.
  • Gate: reversible (two-way arrows)
  • Measurement: several possibilities reduced to one result (one-way arrow)

Real-world example

Picture a device with a control lamp and a target lamp. Keep the control on and apply controlled-NOT twice: the first application flips the target, and the second returns it to its initial state. The control remains unchanged; what repeats is the gate operation, not switching the control on again.

This is a made-up example for illustration, and the lamps here have only two classical states, not qubits.

In the motion model below, the left control stays fixed while the target flips and returns. It illustrates the basis-state rule and another application of the gate, not a measurement or the full quantum superposition.

A basis-state model: applying CNOT again restores the target while the control stays unchanged.

Common misunderstandings

CNOT does not read a result out. A measurement is the reading step, and it collapses the superposition.

CNOT is not the only gate needed. It comes with single-qubit gates, and together they build every multi-qubit gate.

A quantum gate differs from a measurement in that every gate is reversible, while a measurement collapses the superposition.

Frequently asked questions

What does CNOT stand for?

Controlled-NOT: it flips or preserves the target qubit depending on the control qubit.

How is CNOT like an XOR gate?

The target qubit’s output state is the result of an operation analogous to the classical XOR gate on the inputs.

Why is CNOT important?

Together with single-qubit gates, it is enough to build any multi-qubit gate.

Can CNOT be reversed?

Yes. Every quantum gate can be inverted by another quantum gate.

Summary

Terms in this article

English and Vietnamese terms, with the meanings used here. Hover, tap or Tab to a term with a dotted underline for an explanation as you read.

CNOT gatecổng CNOT
A two-qubit gate that flips or keeps the target qubit depending on the state of the control qubit.
qubit
The unit of quantum information.
quantum gatecổng lượng tử
A reversible transformation acting on qubits, represented by a matrix.
measurementphép đo
The step that reads a result and collapses the superposition in the register.
XOR
The classical exclusive-OR operation that the target qubit's output resembles.

This article is not marked as viewed

Spotted something wrong or unsafe?

Tell the administrator by email. The message already has the article title and address.

Report this article
See all articles of the topic

Sources

These sources are written for older readers. If they feel hard, read them with an adult.