The Prophet, peace be upon him, said in a famous hadith, ‘Be consistent and moderate [without excessive struggle or heedless neglect] and rejoice [at the reward of it]; for no one’s actions will take them to paradise.’ They [sahabah] asked, ‘Not even you, Messenger of Allah?’ He replied, ‘Not even me, unless Allah, [Exalted is He] covers me in His grace and mercy.’
This hadith was not intended to undermine action. The Prophet [peace be upon him] and his companions were people of intense dedication to good deeds, obedience to Allah [Exalted is He] and avoidance of sin. The hadith guides us to the right attitude and state of mind. An attitude of moderation and consistency knowing that one is ultimately subject to Allah’s mercy and cannot depend upon the quantity and intensity of one’s actions.
Actions are an important factor in gaining Allah’s mercy. To this end, Allah [Exalted is He] makes it clear that His mercy is all encompassing yet is prescribed to the people of taqwa or God-consciousness. He says, ‘My mercy encompasses everything. I will decree it in favour of those who are God-conscious …’. 
One the one hand the hadith exhorts the people of good deeds to not depend on their deeds alone while also giving hope to those who are struggling with sin that there is reason to hope in Allah’s mercy despite their struggles.
If a state of mind is what the hadith seeks from us, the question is, what are the attributes of that state of mind? What is it always keeps us in Allah’s grace no matter where we are with our deeds?
In answer to these questions I want to share three characteristics of the heart that are the secret to attaining Allah’s favour and mercy. These will ensure that our actions rest on a strong spiritual foundation and our sins keep us turning to Allah [Exalted is He] for His forgiveness. They are not actions or deeds but states of mind and spirit and that accompany and adorn every good deed and shackle every bad deed. Because they are states of mind and spirit they are there with us even in our darkest moments of sinfulness so that we are not at peace with sin nor are we complacent with obedience.
Ubudiyyah is servitude or the state of being a slave. We are defined by who we are to Allah [Exalted is He]. He is Rabb or Lord so each of us is a ‘abd or slave. Turning this in to a state of mind and spirit requires constant recognition of Allah as Lord, and constant remembrance of Him with words of praise and glorification.
A slave is owned, is always subject to his/her Lord’s command and will, and finds happiness and contentment in serving Him. He/she has nothing of his/her own, everything a slave possesses is by the Lords grace and generosity. And our Lord is most generous. To be conscious of all of this is to speak of it. To admit it and express it. As the Prophet [peace be upon him eloquently taught us to say at times of distress or sorrow: ‘I am your slave Allah, son of your slave, son of your slave girl, my forelock is in your hand, your commands applies to me, and your decree is just over me. By means of every name that is yours, which you have named yourself with, or revealed in your Book, or taught to one of your creation, kept exclusive to yourself in your undisclosed knowledge, I ask that you make the Qur’an the spring of my heart, the light of my heart, and means for my worry to be expelled and my sorry to be taken away.’ The Prophet [peace be upon him said that if we pray to Allah [Exalted is He] expressing our servitude in this way, Allah will remove our worry and sorrow and replace them with happiness.
The reason why we are commanded to worship is because worship is the expression of servitude. To not worship Allah is to betray our identity in a display of arrogance towards Allah [Exalted is He]. The same is true of speaking to Allah in supplication which is ‘the essence of worship.’ He warns us: ‘Your Lord says, ‘Call on Me and I will answer you; those who are too proud to serve Me will enter Hell humiliated.’
The slave-lord relationship is not an idea or concept to just intellectually understand and believe in. It is real: a relationship between us and a living Lord who is close to us. A relationship that must be sustained with love, reverence, emotion, and intimate conversation. Allah [Exalted is He] tells the Prophet, ‘If My servants ask you about Me, I am near. I respond to those who call Me, so let them respond to Me, and believe in Me, so that they may be guided.’
Pious Muslims of the past like Imam al-Shafi’e composed poetry and eloquent
words to express their relationship and servitude. Such was their commitment
and depth of feeling. Abul ‘Atahiyah once composed these words:
‘Lord, punish me not for I
Admit to what occurred from me
I have no way out but my hope
And your pardon if you grant it and my good opinion
How many slip ups I have scattered in creation
Yet you have been gracious and generous to me
When I think of my remorse over them
I chew my fingers and grind my teeth
People have a good opinion of me although I
Am the worst of people should you not pardon me.’
Our Lord speaks to us in the Qur’an and hadith: ‘O people’, ‘O believers’, ‘O my slaves,’ ‘O my slave’, and he commands us, warns us, exhorts and motivates us, educates and nurtures us. We must respond. We must speak to Him in our words, obey him in our deeds, and be mindful of His presence in our lives.
Humility follows on from servitude. Servitude is a humble state. So, first and foremost, humility is humility before Allah [Exalted is He]. The recognition of one’s insignificance and irrelevance before Him.
Secondly, humility is the opposite of arrogance. Arrogance has been defined by the Prophet [peace be upon him] as ‘rejection of truth and looking down upon people.’ Therefore humility requires openness to truth, acceptance of truth no matter where or who it comes from, and to not consider oneself better than others. When we see people who sin and we feel grateful that we have been blessed with piety and religiosity, it must never be accompanied with judgement of others a feeling of superiority over others; not even the worst of sinners. Who among us does not sin? How do we know how our sins affect how Allah [Exalted is He] views us? What do we know of what will happen to a sinner tomorrow or what will happen to us? A sinner may repent why we turn away from Allah. The uncertainty of our final end must always fill us with humility.
Allah [Exalted is He] hates the arrogant: ‘I will keep distracted from My signs those who behave arrogantly on Earth without any right. Even if they see every sign, they will not believe in them; they will not take the way of right guidance if they see it, but will take the way of error if they see that. This is because they denied Our signs and paid them no heed.’ Based on this and other verses there is a consistent message that Allah [Exalted is He] closes the doorways to guidance to the arrogant and rebellious, always keeps guidance open to those who humble themselves and remain open and sincere to seeking truth. This is true of non-Muslims who are still to find faith, and Muslims who are in sin and struggle to find a way out. ‘Allah guides to towards Himself those who turn to Him.’ 
The Prophet [peace be upon him] warned that ‘the one with a grain of arrogance will not enter paradise’.
Arrogance is just as dangerous when it is caused by piety. Feeling superior to others in a manner that one looks down upon them is a sure way to loose the blessing of piety. This can be cause by one’s ability to worship Allah well, or the opportunity to seek knowledge, serve the deen, engage in da’wah etc. All of this must be down without looking down upon others.
However, feeling happiness and satisfaction at having done good is not arrogance. Our Prophet [peace be upon him] taught us, ‘When your good deeds make you happy, and your bad deeds make you feel bad, you are a believer.’ 
A heart that is adorned with humility is a heat that is inevitably repentant and will find its way back to Allah [Exalted is He] no matter how deep in sin it may be now. It will break every time a sin is committed even if it is committed repeatedly. It will blame itself, admonish itself, and will cry out to Allah for help until Allah [Exalted is He] eventually responds and opens the gate of guidance. Soon the sin that was an addiction will become hated. But the one who revels in sin, looks down upon the pious, and calls to deviance and disobedience is in danger of being left to himself. Punished in the dunya with the inability to feel penitent.
Sincerity is to do something for Allah’s sake. It requires mindfulness and intention when doing a good. The most important thing to remember about sincerity is that, mundane actions can become acts of worship when accompanied by a good action, and good deeds can become redundant of rewards when they are not done for Allah’s sake.
With sincerity and good intention, the pathways to good deeds and reward multiply infinitely. One’s job, relationships, eating and rest, exercise and activity, even one’s whole life can become perpetual worship if one practices being mindful enough to do these things with the intention to serve and please Allah (Exalted is He).
Like servitude, sincerity must constantly be expressed, affirmed and reaffirmed.
Allah [Exalted is He] taught us the following generation declaration of sincerity to Allah. ‘‘My prayers and sacrifice, my life and death, are all for God, Lord of all the Worlds.’ 
The Prophet [peace be upon him] even taught us to declare morning and
evening that our mornings are for Allah’s sake and our evenings are for Allah’s
sake. He taught us to say, ‘We start the morning for Allah’s and the Kingdom starts
the morning for Allah’s sake. All praise be to Allah. There is no God but Allah
alone, He has no partners. His the kingdom, to Him belong all praise, and He
has power over all things. O Allah, I ask you for the good of this for the good
of what is in this day, and the good thereafter, and I seek your protection
from the evil of what is in this day and
the evil thereafter. My Lord, I seek your protection from laziness, and the
evil of arrogance.’ He taught us to say the same the same in the evening.
Similarly there are many duas and adhkar that are a constant regurgitation of the purity of our intention and purpose.
three states represent the secrets to ensure that we receive Allah’s mercy. We
must work to become more and more conscious of them so that they pervade every
aspect of our being. The right state of mind and spirit can propel even the
most meagre actions to unimaginable heights.
 عن عائشة – رضي الله عنها -: أن رسول الله – صلى الله عليه وسلم – قال: ((سدِّدوا وقارِبوا وأبشِروا؛ فإنه لا يُدخِل أحدًا الجنةَ عملُه))، قالوا: ولا أنت يا رسول الله؟ قال: ((ولا أنا، إلا أن يَتغمدَني اللهُ بمغفرة ورحمة)) رواه البخاري
 Surah al-A’raf 7:156
 عن عبدالله بن مسعود رضي الله عنه ، عن النبي صلى الله عليه وسلم قال : ( ما أصاب عبدا هم ولا حزن فقال : اللهم إني عبدك وابن عبدك وابن أمتك ناصيتي بيدك ماض في حكمك عدل في قضاؤك ، أسألك بكل اسم هو لك سميت به نفسك أو أنزلته في كتابك أو علمته أحدا من خلقك أو استأثرت به في علم الغيب عندك أن تجعل القرآن ربيع قلبي و نور صدري وجلاء حزني وذهاب همي ، إلا أذهب الله همه و حزنه وأبدله مكانه فرجا ) . الكلم الطيب لشيخ الإسلام ابن تيمية
 Surah al-Ghafir 40:60
 Surah al-Baqarah 2: 186
 Surah Al-A’raf 7:146
 Surah al-Shurah 42:13
 قال عليه الصلاة والسلام : ( إذا سرتك حسناتك ، وساءتك سيئتك ، فأنت مؤمن ) . رواه أحمد
 Surah al-An’am 6: 162