Backpropagation is the core algorithm used to train neural networks, working backward from the network's output to calculate how much each individual weight contributed to the error in that output, then adjusting those weights to reduce the error next time. It relies on the chain rule from calculus to efficiently compute these adjustments across every layer of the network, from the output layer all the way back to the input.
This backward pass is what makes training deep neural networks with many layers computationally practical, since it lets the network figure out exactly how to nudge millions or billions of individual parameters based on a single measurement of overall error, rather than requiring some other, far less efficient method to test each parameter individually. Backpropagation, paired with an optimization method like gradient descent that actually applies the calculated adjustments, is the foundational training mechanism behind virtually every modern deep learning model, including large language models.
