It is not always possible to know for sure why people hold specific political beliefs or attitudes. However, we can make some conjectures as to why McCarthyism was successful and first and then fell out of favor. Let us look at two main reasons.
First, we can look at the international situation at the beginning and the end of the McCarthy era. The McCarthy era can be said to have started in early 1950. At that time, China had recently become communist. The USSR had recently exploded its first nuclear weapon. A few months after McCarthy’s first speech about communists in the government, the Korean War broke out. In short, this was a time that seemed very dangerous. It seemed as if things were going badly for democracy and capitalism. By 1953, however, this had changed. Communism had not continued to spread. The Korean War was over. It no longer looked as if there was an existential danger to the United States.
Second, we can look at partisan politics. In 1950, the President was a Democrat. Criticism of the US government as “soft on communism” was beneficial to the Republican Party. In part for that reason, essentially no one tried to rein McCarthy in. By 1953, this too had changed. In 1953, the President was a Republican. This meant that McCarthy’s accusations no longer worked in favor of the Republican Party. This was another major factor in the decline of McCarthyism as his fellow Republicans no longer felt much reason to back him.
These are the most important factors that caused support for McCarthyism to wax and then to wane.