Decoherence occurs due to interactions between a quantum system and its environment. For instance, when a quantum particle such as an electron in a nanoscale device interacts with its surroundings, it may scatter off other particles or absorb and emit photons. These interactions cause the quantum states to lose coherence, effectively collapsing the system into a mixed state that follows classical probabilities.