Let G be a finite group and X a conjugacy class of G. We denote rank(G : X) to be the minimum number of elements of X generating G. In the present article, we determine the ranks for two sporadic simple groups, namely the O'Nan sporadic simple group O'N and the Lyons sporadic simple group, Ly. Computations were carried with the aid of the computer algebra system GAP [The GAP Group, GAP-Groups, Algorithms and Programming, Version 4.3, Aachen, St Andrews, 2003, http://www.gap-system.org ].