A center can stand beneath the basket to protect the rim, but in the NBA, that freedom has limits. If a defender stays in the paint for more than three seconds without actively guarding an opponent, the referee can call a violation and award the offense a technical free throw.
The rule sounds simple until a defender switches assignments, moves to stop a drive, or waits for a rebound. Those situations can determine whether staying in the lane is legal. Understanding the exceptions helps explain why some defenders remain near the basket throughout a possession while others get whistled for three seconds.
How the NBA's defensive three-second rule works

Under the NBA's official defensive three-second rule, the count begins when the offensive team controls the ball in the frontcourt. A defender positioned in the 16-foot-wide lane, or the area extending four feet beyond its endline, must actively guard an opponent within three seconds or leave the area covered by the rule.
The lane, commonly called the paint or key, extends from the baseline to the free-throw line. Centers and forwards frequently occupy this space to contest shots, defend drives, and collect rebounds. For defensive three seconds, the NBA also includes the four-foot area extending beyond the lane's endline.
To qualify as actively guarding, a defender generally must be within arm's length of an offensive player and in a guarding position. A separate exception applies when defending the ballhandler.
Defenders can guard any offensive player, and double-teaming is permitted. Zone defense, help defense, and switching are also legal, provided players follow the three-second restriction.
The NBA introduced defensive three seconds for the 2001–02 season, alongside changes that allowed teams to use zone defenses more freely. The restriction prevented defenders from remaining near the basket indefinitely without guarding an opponent.
When the three-second count stops

The count does not continue uninterrupted whenever a defender enters the paint. NBA rules suspend it under five circumstances:
- An offensive player is attempting a shot.
- The offensive team loses control of the ball.
- The defender is actively guarding an opponent.
- The defender completely clears the 16-foot lane.
- The defender is about to establish a legal guarding position.
These exceptions allow defenders to rotate, challenge shots, and respond to offensive movement without automatically committing a violation.
The final exception requires judgment. A defender moving toward an opponent is not necessarily legal simply because a defensive assignment is nearby. Officials must determine whether the player is about to establish a legal guarding position.
For defenders, completely clearing the lane is one way to end the count. Establishing active coverage of an offensive player also allows them to remain there legally.
Why guarding the ballhandler is different
A defender guarding the player with the ball receives an important exception. That defender may remain in the lane without satisfying the usual arm's-length requirement, provided another defender has not taken over active coverage of the ballhandler.
Imagine a guard dribbling toward the basket while a center moves into the paint to defend the drive. The center can remain there while guarding the ballhandler, even without standing within arm's length.
The situation changes when a teammate switches onto the guard. Once another defender actively guards the ballhandler, the center must pick up another opponent or leave the lane before the applicable three-second count expires.
The same principle applies after a pass. A defender cannot continue relying on the ballhandler exception once the player being guarded gives up possession.
Simply watching the ball from the paint does not establish legal guarding. The defender must meet the conditions of the rule rather than use the exception as permission to wait beneath the basket.
Three plays that explain the rule
Following one defender through a possession makes the difference between legal positioning and a violation easier to recognize.
Play 1: A center guards an opponent in the paint.
A center stands near the basket, facing an opposing forward within arm's length and maintaining a guarding position. Even if the possession lasts 15 seconds, the center can remain there because he is actively guarding an opponent.
Play 2: A defender waits beneath the basket.
The offense moves the ball around the perimeter while a center stands alone in the lane, waiting to challenge anyone who drives. No offensive player is being actively guarded, and no exception applies.
If the center fails to establish a legal guarding position or clear the lane before the three-second count expires, the referee can call a violation.
The NBA's Video Rulebook illustrates this situation using a play involving Tony Bradley, who remains inside the key without actively guarding an opponent.
Play 3: A defensive switch changes the assignment.
A center moves into the lane to guard a driving ballhandler. A teammate then switches onto that player, leaving the center without active coverage of an opponent.
The center must adjust by guarding another player or clearing the lane before the count expires. Remaining in the paint without satisfying an exception can result in a violation.
These situations also explain why communication matters during defensive rotations. Players need to recognize switches, identify who they are guarding, and adjust their positions as the offense moves.
What happens after a defensive three-second violation?
A defensive three-second violation results in a technical foul. The offensive team receives one free throw and retains possession, with the ball inbounded from the sideline at the free-throw-line extended nearest the interruption.
The shot clock remains at its previous time or resets to 14 seconds, whichever is greater. If the offense had eight seconds remaining, it receives 14. If it had 19 seconds, those 19 seconds remain.
This is a team technical foul for a rules violation, not a personal foul against the defender. It does not count toward a player's personal-foul total or the automatic ejection threshold for unsportsmanlike technical fouls. The NBA's technical-foul provisions distinguish defensive three seconds from misconduct-related technical fouls.
There is also an exception involving made baskets. If officials whistle defensive three seconds during a successful field-goal attempt, the violation is disregarded. The basket counts, and play resumes as it would after a made field goal.
Defensive vs. offensive three seconds
The NBA also enforces an offensive three-second rule, but the two violations carry different penalties.
Offensive three seconds restricts an attacking player from remaining in the lane for more than three consecutive seconds while the team controls the ball in the frontcourt. Exceptions apply, including when a player makes a continuous move toward the basket to shoot. The penalty is a turnover.
Defensive three seconds applies when a defender remains in the lane without actively guarding an opponent or qualifying for an exception. Instead of losing possession, the defending team gives up a technical free throw while the offense keeps the ball.
Both rules govern positioning near the basket, but they apply to opposite sides of the ball.
Does defensive three seconds apply outside the NBA?
Not every basketball competition follows the NBA's defensive three-second restriction.
FIBA, which establishes the rules used in international basketball competitions, does not impose the NBA's defensive three-second count. Its 2026 Official Basketball Rules, effective October 1, 2026, retain an offensive three-second restriction without introducing the NBA's equivalent defensive rule.
Players moving between NBA and international competitions should understand that defensive positioning rules can differ. Youth and recreational coaches should also check their league's regulations rather than assume NBA rules apply.
The next time a defender lingers beneath the basket, watch whom that player is guarding. Staying in the paint is legal when the defender meets the rule's conditions; waiting there without an active assignment can cost the team a free throw and give the offense another chance to score.