Overfitting is when a model is trained too closely on a dataset, which is usually too small. This leads to an accurate performance on this data, but poor results when tasked with working on new inputs. The model ends up fitting random noise in the data, rather than detecting the patterns.