Let us now consider a p-n junction in which one side a p-type semiconductor and the other side is an n-type semiconductor. The P side has a higher concentration of holes while the n-side has a higher concentration of free electrons. As a result, there is a tendency of the holes in the P-side to diffuse to the N-sides and the electrons in the N side to diffuse to the P-side.
Formation of depletion region: The region on both the n- and P sides which are close to the junction develops a low concentration of charge carriers. This happens because, as the electrons on the N-side diffuse towards the p-side, they recombine with the holes close to the junction.
The same thing occurs with the hole diffusing from the p-side to the n-side. Since a large number of recombinations occur close to the junction, the charge carrier densities close to the junction decrease drastically. This region close to the junction is called the depletion region or depletion layer.
Creation of junction potential: The electric neutrality of the semiconductor material is disturbed the region close to the junction because of the recombination which forms the depletion region. In the p-side of the depletion region, we have an accumulation of fixed negative charge ion since the atoms have acquired electrons from the n-region. Similarly, on the n-type side of the depletion region, there is an accumulation of fixed positive charge ions because the free electrons have moved to p-region.
This double layer of positive and negative charges produces an electric field which exerts a force on the electrons and holes against their diffusion. The potential difference corresponding to this electric field is called the potential barrier (or junction potential or barrier potential VB). This name implies that this potential difference acts as a barrier against the diffusion of electrons and holes from their majority side to the minority side. The magnitude of this potential barrier is about 0.3 V in case of germanium and about 0.7 V for silicon-based semiconductor diodes. The width of the depletion layer being of the order of one micron, the electric field that exists in the depletion layer is of the order of 105 Vm-1, which is indeed very high.