When a driver breaks the rules (causing a collision, gaining an advantage off track, or making an unsafe release in the pits), the stewards decide on a penalty. There is a graded menu of them, and knowing the difference tells you how badly a result is about to change.
Time penalties
The most common are 5-second and 10-second time penalties. The driver serves them at their next pit stop, sitting stationary for the required time before the crew may touch the car, or, if they do not stop again, the time is simply added to their total at the end of the race. A small penalty can drop a driver several positions if rivals are close behind.
Drive-through and stop-go
More serious is the drive-through: the driver must enter the pit lane, drive through it at the speed limit and rejoin without stopping, losing around 20 seconds. Harsher still is the 10-second stop-go, where the car must stop in its box for ten full seconds with no work allowed, then rejoin. Both cost far more than a time penalty.
Grid drops and licence points
Some penalties carry over to the next race as a grid-place drop, common for taking too many engine components over a season, or for a driving offence judged too late in a race to serve. A driver might start, say, five places lower than they qualified.
Separately, the FIA runs a super-licence penalty-points system. Each serious offence adds points to a driver’s licence, and accumulating 12 points within 12 months triggers an automatic one-race ban. Points expire on a rolling 12-month basis, so a clean run gradually wipes the slate. The most severe in-race sanction of all is disqualification, signalled by the black flag covered in flags & signals.