Law 10 - The Method of Scoring
A goal is scored when the whole of the ball passes over the goal line, between the goalposts and under the crossbar, provided that no infringement of the Laws of the Game has been committed previously by the team scoring the goal.
The team scoring the greater number of goals during a match is the winner. If both teams score an equal number of goals, or if no goals are scored, the match is drawn.
When competition rules require there to be a winning team after a match or home-and-away tie, the only permitted procedures for determining the winning team are those approved by the IFAB, namely:
away goals rule
kicks from the penalty mark
Interpretations of Law 1
If a referee signals a goal before the ball has passed wholly over the goal line and immediately realizes his error, play shall be restarted with a dropped ball from the position of the ball when play was stopped, unless play was stopped inside the goal area, in which case the referee drops the ball on the goal area line parallel to the goal line at the point nearest to where the ball was located when play was stopped.