While reading about overclocking processors and GPU I came across the term 'silicon lottery'. On trying to find out its meaning I was able to understand that it is related to being able to overclock your processor to a good extent without any instability. My question is that overclocking fixed for a particular processor model or it depends on the overall hardware (i.e GPUs, RAMs, cooling systems etc.) being used in the computer.
CPUs are very complex and contain billions of tiny transistors, each only a few nm in size. There are bound to be small differences between each CPU manufactured. One of these factors is the critical path which is the longest / slowest path through the CPU. For example, a transistor or bus may have higher capacitance and require a bit more time to switch and stabilise. The clock period must always be greater than the critical path or you risk instability where the results of the calculations are no longer as expected. Two identical CPU models may have different critical paths purely due to silicon quality differences in the die.
CPU manufacturers want a high yield (CPUs that pass testing) so they set a conservative clockspeed so that most CPUs pass. They set this figure so that a high % of CPUs pass but not so low that there is a big performance penalty. However, you do not know how far each CPU can overclock as it was only tested for this minimum clockspeed. Sometimes, CPU manufacturers will test CPUs at various clockspeeds and base their model based on their 'silicon quality'.
Overclockers can increase the voltage of the CPU to force transistors to switch more quickly (and reduce or change the critical path) but this comes at a cost. As you increase voltage, the power consumption and therefore heat output, increase exponentially. It can also significantly affect the lifetime of your CPU and stress the voltage regulators on your motherboard. If you have a CPU with poor silicon quality, you will find yourself having to use a lot more voltage in order to reach the same clock speed as an identical cpu with good quality silicon.
A typical overclock will be limited by your CPU cooling, motherboard VRMs or your decision on how much voltage to apply. If you change the base clock of your CPU, this also affects everything else connected to the CPU so RAM and GPU will also come in to play. This is an advanced method of overclocking and most people will just use ratio adjustments so this will not really come in to play.
You do not need to worry too much about overclocking too far as you can simply remove it by resetting your bios (Remove cmos battery for 30 seconds or so). The most likely thing to occur with a bad overclock is a blue screen of death or kernel panic which should disappear once the clock speed has been reset.
TL;DR: How far you can overclock your CPU is based on luck. You can increase your chances of an overclock by buying a binned CPU which was tested for stability at higher clock speeds.