Why did the us sell military equipment to the shah of Iran?

Selling of Arms and Ammunition is a big business for America. It is a big Industries and therefore US will supply arms to any country for commercial reasons. It even supplied arms to Iraq to fight the Iranians!