Wikipedia:
In 1954, the Soviet Union transferred Crimea to the Ukrainian SSR from the Russian SFSR. The transfer to Ukraine was made by Soviet leader Nikita Khrushchev. The year 1954 happened to mark the 300th anniversary of the Treaty of Pereyaslav, which was signed in 1654 by representatives of the Ukrainian Cossack Hetmanate and Tsar Alexis of Russia.
My note:
Gorbachev “let” them keep it upon the breakup of the Soviet state.
I stand corrected.
SRC="https://www.sott.net/image/s22/447360/large/static1_squarespace_com_.png"