Validation is measuring how well a model has learned by testing it on data it never saw during training. Performance on the training data says nothing on its own, since a model can score highly by memorising those examples. The real question is what it does with a record it has not seen.
The process sits inside training. At the end of each epoch the model runs against the validation set and the score is recorded. The moment training loss keeps falling while validation loss starts rising is the moment overfitting begins. Settings are chosen against this score too: learning rate, layer count, regularization strength and when to stop.
When data is scarce, cross-validation takes over. The set is cut into five folds, each fold serves as validation in turn, and the five scores are averaged. The result then does not hang on one lucky split.
A concrete case: an ecommerce site builds a model to predict product categories. A random split gives high validation accuracy, but variants of the same product sit in both training and validation, so the score misleads. Splitting at product-family level lowers the number and moves it closer to real performance.
The validation score is not the headline figure. Because settings were tuned against that set repeatedly, the final measurement comes from a test set nobody has touched.

