In addition to the many examples already provided above, you may also add General Pinochet's regime in Chile following the assassination of Salvador Allende in 1973. Allende had established a socialist government, which at the time was interpreted as communist by United States foreign policy and national security guidelines. General Pinochet led the Chilean Army against Allende's government with CIA backing, killing Allende and setting up Chile as a martial-law state. Although the Chileans finally removed Pinochet by peaceful protest, his years in office translated to thousands of Chileans being killed and abused by military personnel. Pinochet is now being tried for the abuse of human rights, but I think it's appropriate to say that the United States had a hand in this period of Chile's history.
I should also mention the Contras in Nicaragua. The United States viewed the Sandinista government in Nicaragua as a real threat in Central America, and established a Contra-Sandinista force to act as proxy soldiers in Nicaragua. The School of the Americas, located on American soil and widely protested even now, acted as the training camp for these Contras. Once training was finished, the Contras were moved to Nicaragua, where they fought against the Sandinista government and its socialist functions, often by destroying any buildings that the Sandinistas had made. Nicaragua's infrastructure and economy are still a mess, left over from the Contras' apparent "scorched earth" policy, and the country itself is the second poorest in the hemisphere. Only Haiti is poorer.
The history of U.S.-Iran relations is pretty clear: the United States facilitated the overthrow of the government of Mohammad Mosaddegh and replaced him with the Peacock Throne in the person of the Shah. While the Shah's regime was a reasonably cooperative ally in resisting communism in the Persian Gulf region, one would be hard pressed to argue that the revolution served the interests of the Iranian people. The Iranian economy certainly grew a great deal during the Shah's reign, and he brought a far higher level of modernity to Iranian society, but his was a very repressive rule characterized by the imprisonment of many political foes and dissidents. His internal security service, the SAVAK, was known for its brutal treatment of political prisoners.
The United States also played a direct role in the military coup d'etat that replaced the liberal government of Jacobo Arbenz with a pro-U.S. regime that certainly helped prevent the spread of Cuban and Soviet-inspired communist insurgencies in Central America. There is no way, however, that this educator would argue that the coup was good for the people of Guatemala, a desperately poor country. Arbenz's proposals for land reform in a country where such measures were warranted would have provided better opportunities for the native Mayan and other "Indian" tribes that occupied the lowest rungs of Guatemala's economic spectrum.
As far as Afghanistan is concerned, the United States drove the Taliban out of power following the September 11, 2001, terrorist attacks and facilitated the rise of a western-oriented government. That such a governing entity is alien to that particular country does not mean it was wrong to try. That the Taliban had to be removed was universally -- outside of Pakistan and Saudi Arabia -- acknowledged. The Taliban were so extreme in their interpretation of Quranic law that even the ruling Mullahs in Iran wanted them removed.
First, I would say that it is better to say “support” than “establish” here because there are very few, if any, cases in which we can definitively say that the US established a certain government in power. For example, it is clear that the US helped to overthrow Mohammed Mossadeq in Iran in 1953. However, is it right to say that the US “established” the Shah’s government? We would not say that France “established” the US government even though it helped the US throw off British rule. Iran and other places like that were not places in which the US literally came in, remade the government and set its own person in power. Instead, it simply played a large role in removing one government and in supporting a new government.
Second, it is very hard to say what sort of government is good for the people of a country and what government is not. It is even harder to say that a government was worse than the alternative. For example, the US has helped to establish the Karzai government in Afghanistan today. That government is, arguably, bad for its people. But that is a subjective judgment. Moreover, it is not clear that the alternative (the Taliban or multiple warlords) would be better.
All that said, there were countries in which the US strongly supported governments that were arguably bad for the people. Iran is one of them. Guatemala is another. South Vietnam can be seen in this way. The Marcos regime in the Philippines was not very good for its people. Mobutu Sese Seko can be seen as a disaster for what was then Zaire. The US also supported, though it cannot be accused of installing, the apartheid regime in South Africa and anti-democratic governments in Taiwan and South Korea.
The facts pertaining to the history of the Contra movement, the Sandinistas' rule once in power, and the democratic process that resulted from U.S. support for the Contras is best summarized as follows.
The Sandinistas fought a revolution against a brutal dictator, Anastasio Somoza Debayle, but, once in power themselves, established a totalitarian regime that was actually more universally repressive than the regime it replaced. U.S. support for the anti-Sandinista rebels, the Contras, was a legitimate act against a hostile dictatorship.
The origins of the Contras was that most of the early rebels had been Sandinista supporters, but opposed the dictatorship the Sandinistas established. They had fought against one dictatorship, Somoza, only to see a worse one take its place. As a direct result of U.S. support for the Contra movement, the Sandinistas eventually agreed to democratic elections, which they lost to another former opponent of Somoza, Violeta Chamorro, whose husband was a newspaper publisher highly critical of the Somoza government. Ultimately, Violeta Chamorro's husband was assassinated by Somoza's security service. She had more reason to oppose Somoza than Daniel Ortega, the leader of the Sandinistas, yet she grew to oppose the Sandinistas also because of their brutal rule.
With regard to Chile, the United States, through the CIA, actively supported a coup attempt against Allende in 1970. That attempt failed. Three years later, the Chilean military carried out a successful coup d'etat, during which Allenda was killed. That successful coup did not involve the CIA. General Augusto Pinochet, the leader of the Chilean Army who became president after Allenda's death died in 2006.