The Soviet Union ended with the formation of the Commonwealth of Independent States. At the time of dissolution of the Soviet Union, Mikhail Gorbachev was the president of the Soviet Union. He was in this position for a little over a year but he was leader of the Soviet Union from March 11th 1985. On 25 December 1991, he quit the post of the president of the USSR. By 31 December 1991, all organizations and departments of the Soviet Union stopped working. On that date, the Soviet flag flew for the last time on the Kremlin.