Can You Be Offsides on a Goal Kick?
According to the official rules of soccer, there is no offside if a player receives the ball directly from a goal kick.
This means that if the ball is kicked from the goal area and a player on the receiving team is behind the last defender, they cannot be called offsides.
The offside rule will apply once an outfield player touches the ball.
In addition to goal kicks, a player cannot be flagged as offsides on throw-ins and corner kicks.
I’ve gone in-depth about the offside rule which you can find here.