A goal may be scored directly from a goal kick, but only against the opposing team; if the ball directly enters the kickerís goal, a corner kick is awarded to the opponents.
The ball must be stationary and is kicked from any point within the goal area by a player of the defending team
The ball is in play when it is kicked and clearly moves
Opponents must be outside the penalty area until the ball is in play
2. Offences and sanctions
If, after the ball is in play, the kicker touches the ball again before it has touched another player, an indirect free kick is awarded; if the kicker commits a handball offence:
a direct free kick is awarded
a penalty kick is awarded if the offence occurred inside the kickerís penalty area, unless the kicker was the goalkeeper, in which case an indirect free kick is awarded
If, when a goal kick is taken, any opponents are inside the penalty area because they did not have time to leave, the referee allows play to continue. If an opponent who is in the penalty area when the goal kick is taken, or enters the penalty area before the ball is in play, touches or challenges for the ball before it is in play, the goal kick is retaken.
If a player enters the penalty area before the ball is in play and fouls or is fouled by an opponent, the goal kick is retaken and the offender may be cautioned or sent off, depending on the offence."
Taken from Laws of the Game, 2022/23.