"The heedless one says "Subhan Allah"
(glory to Allah) out of habit. As for the conscious one, he is constantly thinking about the wonders of creation, or the awesome nature of the Creator, and this thinking drives him to say: 'subhan Allah.' So, this tasbih is the fruit of these thoughts, and this is the tasbih of the conscious… Likewise, they think about the ugliness of past sins, and this leads them to ponder, to have anxiety, to have regret. The fruit of this thought is that they say: 'astaghfirullah.'
(I seek Allah's Forgiveness). This is the true tasbih and istighfar.
As for the heedless, they merely utter these out of habit. And what a difference there is between the two types…"
Ibn al-Jawzi (ra)