# Fermi energy level

Definition of Fermi level: Fermi level is defined as the energy level in which the probability of OCCUPANCY of an electron is 1/2.

My question:

For semi-conductors, Fermi level is in between valence and conduction bands. But electrons can occupy only definite energy states i.e an electron can be in valence band or conduction band. How can it be in between them?

For example: An electron can be in ground state or first excited state.It cannot be in between them.

The probability to find an electron on a given energy level is not given by Fermi_Dirac function alone but by the product of the function and the density of states. More specific, $p(dE)= f(E)g(E)dE$ where dE is a small energy interval around the energy E and g(E) is the density of states. In the band gap the density of states is zero so it does not matter that f(E) is finite. There are no electrons there.
Note that that the distribution function is 1/2 when E is equal to the chemical potential $\mu$. Fermi level is the maximum level occupied at zero K. The chemical potential changes with temperature. However it is a quite common practice to use "Fermi level" instead of "chemical potential".