A quantum gate is a basic operation on one or more qubits that forms the building block of quantum circuits. Mathematically, quantum gates are represented as unitary matrices — transformations that are reversible and preserve the total probability of the quantum state. This reversibility is a fundamental constraint: unlike classical gates (e.g., AND, OR), which can lose information, every quantum gate must have an inverse that undoes its operation.

Single-qubit gates manipulate individual qubits and correspond to rotations on the Bloch sphere. Common examples include the Pauli gates (X, Y, Z), Hadamard (H), phase gate (S), and T gate. Two-qubit gates create or manipulate entanglement between pairs of qubits, with the CNOT (controlled-NOT) and CZ (controlled-Z) being the most common. Any quantum computation can be decomposed into a sequence of single-qubit gates and one type of two-qubit entangling gate — this is the concept of a universal gate set.

In practice, quantum gates are implemented as precisely calibrated physical pulses. For superconducting qubits, microwave pulses of specific frequency, duration, and shape implement gate operations. For trapped ions, laser or microwave pulses drive transitions between qubit states. Gate quality is measured by fidelity — the probability that the gate performs the intended operation correctly. Gate errors arise from imperfect calibration, decoherence during the gate, and unwanted interactions with neighboring qubits (crosstalk). Achieving high gate fidelity across all qubits in a processor is essential for scaling quantum computation.