Khrushchev may have wanted the missiles there in order that he might be able to bargain with the USA, so that he could agree to remove them for some American Concessions. It has also been said that the USSR wanted to test Kennedy and the USA to see how string they were and whether they would back off or face up to the situation and additionally to trap them into being drawn into a nuclear war.
However it was also believed that Khrushchev genuinely wanted to protect Cuba and Fidel Castro. Cuba was the only communist regimes so close to the USA. Its very existence as a strategically placed communist state would show the USA that communism was a force to be reckoned with. In 1962 the Americans carried out a practise invasion of Cuba with 40,000 marines; this was supposedly done to deflect the Cuban and Soviet attention from south and central America but it had the effect of making Khrushchev and Castro believe that a real invasion was imminent and for them to step up their efforts to arm Cuba.
Soviet public perception was another reason why Khrushchev put nuclear missiles in Cuba. He wanted to be perceived as a strong leader by the Soviet people. Khrushchev had become leader of the Soviet Union in 1953 after Stalin had died. He had strong and successful home policies in agriculture and industry but he also wanted to be seen as an international politician. Khrushchev thought he could force President Kennedy to allow a nuclear base in Cuba and silence any criticism of his policies in the USSR.
Furthermore, The Bay of Pigs fiasco gave Khrushchev reason as to why he decided to put nuclear missiles in Cuba when he did. This incident was in 1961 when newly elected President John F Kennedy broke off diplomatic relations with Cuba completely and helped some anti Castro exiles to invade Cuba and overthrow him. Kennedy provided arms, transport and equipment. In April 1961, the exiles landed on Cuba at the Bay of Pigs and were beaten by 20,000 Cuban troops.
In conclusion there were several reasons why Khrushchev put nuclear missiles in Cuba. The USSR was concerned about the USA’s policy of containment against communism. The arms race and missile gap was of great concern to Khrushchev and the people of the Soviet Union. Khrushchev wanted to look like a strong leader to the Soviet people. The courting of Fidel Castro and the overthrow of the government in Cuba by Castro, who was friendly with the USSR, gave Khrushchev a prime site within reach of the USA in which to build up an arms base near to the USA. The Bay of Pigs fiasco gave him the excuse to build up arms openly in Cuba as he wanted to protect Castro and his regime, the only communist regime so close to the USA, from any other attack the USA might do to Cuba.