ভূমিকা
Surely I see you and your people in manifest error.” Thus We were showing Ibrahim the kingdom of the heavens and the earth so that he might be of (al-muqinin) those who are sure [of their faith].
So when the night outspread over Ibrahim, he saw a star; he said, “This is my Lord.” But when the star set [in the morning,] he said, ”[This cannot be my Lord because it has passed away,] I do not like the transitory [gods].” [On the next night,] when he saw the moon rising, he said, “This is my Lord.” But when the moon set he said, “If my Lord had not guided me, then I shall surely be of (adh-dhaliyn) the people who have gone astray.” [In the morning,] when Ibrahim saw the sun rising, he said, “This must be my Lord [because] this is greater [than the star and the moon!]” But when the sun set, he said, “O my people, surely I am free from what you associate [with Allah.] I have sincerely turned myself to Him who originated the heavens and the earth, and I am not one of the polytheists.” Many historians of religion take Ibrahim as the founder of the monotheistic idea.
This definitely goes against the Islamic view that monotheism was the original faith of mankind from the days of Adam (a.s.), and that later on people became polytheists. The Qur'anic statements quoted above have been used as a proof of the evolutionary phases in Ibrahim from polytheism to monotheism. This is, obviously, an incorrect reading of the Qur'an. This entire passage quoted above actually shows that Prophet Ibrahim was actively engaged in combating idol - and nature-worshipping.
Reading the whole passage does not raise any problem about the 'ismah of Prophet Ibrahim. He did not raise the possibility of the star, the moon and the sun being gods as a fact; it was raised only as a part of his method of disproving such a possibility. In debates, it is quite common to initially accept the view of your opponent in order to lead him to your own view.