A 'lane violation' in basketball is an infraction that occurs when a player is caught standing in the painted area of the court (box-shaped area near the basket) for three seconds. Lane violations are called by the referee, who blows the whistle to stop play and announce the infraction.
The 'lane' is located inside of the three-point line (the arch that extends from sideline to sideline) on each half of the court. It is fairly easy to spot, characterized by a rectangular shape that is painted a different color from the rest of the court. Another common name for this area is the 'key.'
Offensive players and defensive players can be guilty of standing in the lane for three or more seconds. When a member of the offense commits a lane violation, the team currently in control of the ball must forfeit possession to the opposing team.
Defensive three seconds is slightly more complicated, as it results in what is known as a 'technical foul.' When a technical foul occurs, the offense is awarded one foul shot (attempted by a player of their choice) followed by gaining possession of the ball.
Lane violations can be avoided by briefly exiting the painted area before a three-count is reached by the referee. Once a player fully exits the lane, they are permitted to re-enter with a fresh count.
The referee does not begin counting if the offensive player is actively attempting a shot from the lane. Thus, it is important for offensive players to avoid merely dribbling the ball in the same spot upon receiving a pass. Defenders are also given the opportunity to guard an opposing player that is within a reasonable distance of the lane, with the count being suspended until a defender continues to stand in the area once it has been vacated by the opposition.