Thank you for the opportunity to help you with your question!
One of the main reasons the United States felt the need to fight communist uprisings in several smaller, strategically unimportant nations was the Domino Theory. The Domino Theory was propagated after World War II (WWII) ended, largely as a result of a communist uprising in French-controlled Vietnam. Policy analysts in Washington worried that a successful communist revolt in Vietnam would encourage the communist factions of other Southeast Asian nations to similarly rise, causing the other precarious monarchical, capitalist states of Southeast Asia to fall to communism one after another, like dominoes.
This theory was first articulated to the American public by President Dwight Eisenhower in an April 1954 speech. Eisenhower was trying to bolster domestic support for increased aid to the French forces and government in South Vietnam, and he stated his fears that the loss of Vietnam to communism might encourage the rest of the region to become communist too, perhaps even endangering Japan who depended upon Southeast Asia for trade. The Domino Theory largely motivated American foreign policy in Asia over the following decades.
McCarthyism began well before Senator Joseph McCarthy arrived on the scene, and its origins are complicated. Much of it was rooted in fear and anxiety within the Republican Party's reactionary fringe. The United States had experienced a similar phenomenon from 1917-1920 in reaction to the Bolshevik Revolution in Russia, which represented the emergence of communism as a political movement. Civil liberties were strictly curtailed by the Espionage and Sedition Acts, especially free speech. After the war, a wave of leftist bombings, labor discontent, and a distrust of immigrants resulted in the First Red Scare, characterized by aggressive Justice Department investigations, severe violations of civil liberties, mass arrests and deportations, and several high-profile convictions. But during the 1930s the Communist Party of the United States gained influence as the image of Communism improved. They championed labor rights and were the bitter enemies of right-wing fascists, especially Nazis. During the worst of the Great Depression, some Americans questioned whether capitalism had failed. Some sincerely believed in the egalitarian promise of communism (and were later bitterly disappointed by its repressive tendencies). Others experimented with leftist ideas as a youthful indiscretion--because it had become popular on campus or within their social circles. During WWII, with the United States and the Soviet Union temporarily allies, anti-communist rhetoric mostly ceased. With the war's end, however, the Soviets quickly reneged on the promise to hold free elections in territory conquered from Germany and instead installed repressive puppet regimes. Much of Central and Eastern Europe had been freed from Nazism only to become satellite nations of the Soviet Union.
Please let me know if you need any clarification. I'm always happy to answer your questions.
Content will be erased after question is completed.