The following are general types of penalty enforcement. Specific rules will vary depending on the league, conference, and/or level of football.
Most penalties result in replaying the down and moving the ball toward the offending team's end zone. The distance is usually either 5, 10, or 15 yards depending on the penalty. However, such penalties, when enforced, are capped at half the distance to the offending team's goal line.
Depending on the foul, the spot where the penalty is enforced may be at the spot of the foul; the previous spot (the line of scrimmage where the down began); the spot of the snap, fumble or backwards pass; or the succeeding spot (the line of scrimmage of the next down).
Some defensive penalties give the offense an automatic first down. Conversely, some offensive penalties result in loss of a down (loss of the right to repeat the down). If a penalty gives the offensive team enough yardage to gain a first down, they get a first down, as usual. However, if the offense commits a foul in its own end zone, the defense scores an automatic safety if the penalty is accepted.
If the defense commits a foul during the last play of any quarter, the offense usually has the option to accept the penalty and replay the down even with the clock showing 00:00 (i.e., an untimed play). Conversely, in most cases where the offense commits a foul during the last play in the half, the play in which the foul is committed is usually nullified and the half ends.
When a "double foul" occurs, when both teams commit a foul during a play, regardless of severity, the fouls are usually offset and the down is replayed. However, the two fouls must be committed in the same time frame. For instance, two fouls during the active play can offset, but a foul during the play and a personal foul after the whistle may not. Two personal fouls after the play can offset, although this is not often called. In the NFL, a major (15 yard) penalty by one team may not offset a minor (5 yard) penalty by the other team.