Iran has been ruled by Turkic dynasties for most of the last thousand years, but despite scattered pockets of Turkic languages elsewhere, only in the northwest did the majority of the population switch to using Turkish.
When did Azerbaijan (the historical region, not just the republic) come to be majority Turkish speaking? What factors would have contributed to this one region of Iran being the only one to adopt Turkish?
They speak Azeri, a Turkish dialect. They really didn't "switch" to speaking it, they spoke it before. In fact the entire region including what is now the country of Azerbaijan, used to belong to Iran and was lost to the Russians in a series of wars the culminated in 1828. Iran is a multilingual and multiethnic society.