Some Islamic reform movements were intellectual, some were social, and some were both intellectual and social. Ghazalis movement was purely intellectual. He thought that Islamic sciences and Islamic intellectualism fell and was trying to enliven religious sciences.

He life shows that he was always after the truth through research. He changed his mind many times while he was along this path. He stated about himself:

“From my childhood until the present, while I am fifty years of age, I have always looked into the viewpoints of other sects and nations. I have reviewed religious ideologies, philosophies, mystic patterns, theology, etc. The great thirst that I had for discovering the truth has been inside of me since childhood. This caused me to break the chain of imitation and doubt about inherited beliefs because I saw that Christian children only look at Christianity; Jewish children only look at Judaism; and Muslim children only look at Islam. The Prophet (s) has stated: ‘Every child is born with a pure divine disposition.’ Therefore, I was instigated to find the truth; to find the roots of my beliefs.” [Yadnamah Shahid Mutahhari, v.2, p.140]

After he finished in preliminary studies he went to Nayshapur to study with the head of the ‘two shrines,’ Javini. He benefited from Javini his teacher passed away (478 h.). At this time was less than twenty years of age and was considered a mujtahid. He left Nayshapur and headed for Baghdad where he taught at a military school. [Nahadha va Andishahha-i Siasi dar Iran va Islam, by Hamid ‘Anayat, p.118]

Later he became the head of the military congregation in Baghdad which was the highest position a religious scholar could have at that time. But, he felt that his knowledge and that position did not satisfy him. He would hide himself from the people and try to purify himself. He stayed in Jerusalem, away from all those that knew him, for ten years where he practiced mysticism (‘irfan). He did not take any other position for the rest of his life. The book Ahya ‘Ulum al-Din was written after he purified himself. He passed away in the year 505 h. in Tus, his original hometown.

via Islam Times – Ghazali and Islamic Reform 1.