The most widely accepted definition of all time career statistics are those recorded in official senior games - basically all games at senior level except club friendlies.
However, Messi and Ronaldo also scored many goals at youth level, which are sometimes included in certain lists/records.
All Messi Goals Including Youth
Team
Goals
Matches
All Senior Club
738
892
Argentina
112
190
Barcelona B
6
22
Barcelona C
5
10
Argentina U23
2
5
Argentina U20
14
18
Total
877
1137
All Ronaldo Goals Including Youth
Team
Goals
Matches
All Senior Club
775
1034
Portugal
133
216
Sporting CP B
0
2
Portugal U23
2
3
Portugal U21
3
10
Portugal U20
1
5
Portugal U17
5
7
Portugal U15
7
9
Total
926
1286
All Time Top Goalscorers
Unfortunately, there isn't a crystal clear list of the top goalscorers of all time because the records and stats of players from decades past are patchy and incomplete, in addition to varying definitions of which goals should count.
The two most frequently shared all time top scorer lists are courtesy of IFFHS (International Federation of Football History & Statistics) and RSSSF (Rec.Sport.Soccer Statistics Foundation).
IFFHS All Time Top Goalscorers List
The IFFHS list takes into account only goals scored in "top-level competitions", which discounts youth goals and goals scored in regional competitions by players such as Josef Bican.
Rank
Player
Goals
Years
1
Cristiano Ronaldo
908
2002-present
2
Lionel Messi
850
2004-present
3
Pelé
762
1957-1977
4
Romário
755
1985-2007
5
Ferenc Puskás
729
1943-1966
6
Josef Bican
720
1931-1955
7
Jimmy Jones
647
1947-1964
8
Gerd Müller
634
1964-1981
9
Eusébio
619
1958-1981
10
Joe Bambrick
616
1926-1943
RSSSF All Time Top Goalscorers List
The RSSSF list takes into account goals scored in competitions at all levels. The + indicates that some matches are unaccounted for and so the number of goals/matches could be higher.
Rank
Player
Goals
Matches
Ratio
Years
1
Erwin Helmchen
987+
577
1.71
1924-1951
2
Josef Bican
950+
624
1.52
1931-1957
3
Ronnie Rooke
931+
1028
0.91
1930-1961
4
Cristiano Ronaldo
926
1286
0.72
2002-present
6
Lionel Messi
877
1137
0.77
2004-present
5
Jimmy Jones
833+
751
1.11
1944-1965
7
Ferenc Puskás
806
793
1.02
1943-1967
8
Ferenc Deák
795+
511+
1.56
1939-1959
9
Romário
784
1002
0.78
1984-2009
10
Abe Lenstra
783+
843+
0.93
1936-1963
If you're looking for more all time goals stats, tweet us at @mvsrapp, and we’ll do our best to help.