Government set up to rule for a short period until a proper one can be elected, due to dramatic events disrupting the normal formation process. Such a non-democratic government may not be ideal, but is preferred to the alternative of anarchy.
Back in the olden days, a dramatic event was normally the unexpected death of an absolute ruler who did not leave any obvious heir. To prevent civil unrest while the potential new rulers fought among themselves, someone might be picked to govern until the best decision has been made. This method was much too reasonable to be used often, but an example is the Roman emperor Nerva. He was an elected interim ruler from 96 AD until his death, fifteen months later. His adoption of Trajan made the succession to the next emperor smooth and uncontroversial.
In modern times, interim governments are often placed in office by the international community after the former regime has been overthrown and the country attempts to re-orient itself. Leaders of the opposition are strong candidates for this job. The importance lies in picking people who are strong enough to leave voluntarily if they do not receive the majority of the votes later on.
Forming an interim government to bring order after a civil war is even trickier. Both sides should be represented and able to cooperate. If this succeeds, the country has taken an important step towards peace and democracy, away from chaos and hatred.