We explore the mass-to-light ratio in galaxy clusters and its relation to the cluster mass. We study the relations among the optical luminosity ($L_{op}$), the cluster mass ($M_{200}$) and the number of cluster galaxies within $r_{200}$ ($N_{gal}$) in a sample of 217 galaxy clusters with confirmed 3D overdensity. We correct for projection effects, by determining the galaxy surface number density profile in our cluster sample. This is best fitted by a cored King profile in low and intermediate mass systems. The core radius decreases with cluster mass, and, for the highest mass clusters, the profile is better represented by a generalized King profile or a cuspy Navarro, Frenk & White profile. We find a very tight proportionality between $L_{o...