The Soviet constitution let every republic secede, and in 1991 some did
On paper, each Soviet republic had the right to leave the Union. For decades that right was dismissed as meaningless, since the Communist Party ran everything from the centre. Then in December 1991 Russia, Ukraine and Belarus invoked Article 72 of the 1977 constitution to secede, effectively dissolving the Soviet Union.
The USSR was founded in 1922 by treaty among four Soviet republics: Byelorussia, the Russian SFSR, the Transcaucasian Federation and Ukraine. The number of union republics later ranged from 4 to 16, and from 1956 until 1991 it stood at 15. The 1977 constitution called each one a sovereign socialist state that had joined the others voluntarily, and promised its territory could not be altered without its consent.
Reality was far more centralised. Alongside the state ran a parallel party hierarchy, letting the Politburo steer the republics, and every senior appointment needed approval from the centre. Historians such as Dmitri Volkogonov have argued that the Soviet Union was a unitary state in practice though not in law. Ukraine even had its own foreign minister in the 1930s, an office with no real sovereignty behind it.
Some trappings of statehood still mattered. Amendments in 1944 allowed republics their own foreign affairs and defence commissariats, which in 1945 gave Ukraine and Byelorussia their own founding seats in the UN General Assembly, alongside the USSR itself. Each republic had its own flag and coat of arms, most had anthems, and ruble banknotes carried text in the languages of all 15.
Membership was not fixed. The Karelo-Finnish SSR, created in 1940 after the Winter War, is the only republic ever demoted, folded into the Russian SFSR in 1956 without consulting its people; the official reasons cited a largely Russian, Belarusian and Ukrainian population and the cost of its administration, 19.6 million rubles in 1955. Others knocked on the door: Bulgaria's Todor Zhivkov proposed joining in 1963 and again in the early 1970s, only to be turned down by Khrushchev and later by Brezhnev.
Source: Republics of the Soviet Union