Benefits of Obeying Allah
Question

I am thirty years old. I was sinning till five years ago, yet I was praying. Then I got married and travelled to France.
Many problems happened to me and I found that the only solution is to return to Allah and repent. So I repented, all praise be to Allah. I started memorising the Quran and seeking Islamic knowledge. I fast the optional fasting throughout the year, I do not miss any prayer in the masjid except rarely; I do not miss the first Takbirah (opening) of any salah (formal prayer) for forty days. All praise be to Allah as He should be praised. As a result of this, my circumstances improved a lot, and I felt a very big positive change in myself as well. The more I obey, the more Allah blesses me, Allah is watching, He knows I am truthful.
The problem is that I do not know why I am exerting effort in worship; is it for the gain of the hereafter or for worldly benefits? If I give in charity for example, I am not sure if I am really seeking the pure reward or because I know that Allah will bless me with much more than what I gave in charity. I am starting to doubt myself; am I a hypocrite?
Praise be to Allah.The Gift of Repentance: A Path to obtaining the Love of Allah
I congratulate you, my brother, on having been guided to repent to Allah and come back to the right path. This is a blessing that has been bestowed upon you for which you should be thankful, because it is the aim of every believer, and this is the most important thing in this world and the Hereafter.
Ibn Al-Qayyim (may Allah have mercy on him) said:
Allah does not grant His love to the penitents but they become the elite of people before Him. Were it not that repentance is a word that encompasses all the laws of Islam and truths of faith, the Lord would not rejoice so greatly over the repentance of His slave. (End quote from Madarij As-Salikin, 1/343)
How Obeying Allah Opens Doors of Provision
The fact that the harder you strove in worship, the more means of finding lawful provision became available to you shows that fearing and obeying Allah brings provision, as Allah says (interpretation of the meaning):
{And whosoever fears Allah and keeps his duty to Him, He will make a way for him to get out (from every difficulty). And He will provide him from (sources) he never could imagine.} [At-Talaq 65:2-3]
Sins and Poverty: Understanding the Connection
Similarly, sin brings poverty. A person may be deprived of provision because of sins that he commits. Nothing brings provision like doing acts of obedience and avoiding sins.
The Importance of Pure Intentions in Acts of Worship
But you have to pay attention to your intention before you start to act, so that the motive for doing good in the first place will be to seek the pleasure of Allah, and you should keep an eye on your intention and guard against it being corrupted during and after the action, so that you can rid it of self-admiration, showing off, and seeking praise and status in people’s hearts because of it, and avoid doing it because of what it brings you of good things in such a way that if your provision was reduced you would stop doing it. These are all things that are contrary to sincerity and spoil acts of obedience.
Ibn Al-Qayyim (may Allah have mercy on him) said:
The things that spoil and cancel out good deeds are too many to list. What matters is not the deed; what matters is protecting the deed from that which would spoil it and cancel it out. (End quote from Al-Wabil As-Sayyib, p. 20)
Seeking Both Worldly and Eternal Rewards: Is It Allowed?
It should be noted that if a person’s intention in doing acts of worship is to seek the pleasure of Allah and His reward in the Hereafter, and he also intends to seek the immediate reward of obedience in this world, such as ample provision, a good life and so on, there is nothing wrong with that.
Allah has encouraged us to obey Him and to avoid disobeying Him, by mentioning the reward in this world, which indicates that there is no blame on the believer if he seeks it.
Ash-Shaykh Ibn `Uthaymin (may Allah have mercy on him) said: If a person intends two good things by his action: the good of this world and the good of the Hereafter, there is nothing wrong with that [i.e., no blame and no sin on him] because Allah says (interpretation of the meaning):
{And whosoever fears Allah and keeps his duty to Him, He will make a way for him to get out (from every difficulty). And He will provide him from (sources) he never could imagine.} [At-Talaq 65:2-3] (End quote from Al-Qawl Al-Mufid, 2/244)
Gratitude: A Key to Increasing the Blessings of Allah
Do not let the Shaytan tell you that you are a hypocrite or insincere, because his aim is to divert you from doing righteous deeds and to lead you astray from the path of good. Do not let your motive in doing acts of obedience be the provision that they bring, in such a way that if the benefits were to dry up you would stop doing them. Rather make your deeds sincerely for your Lord, and thank Him for the good things that He has bestowed on you:
{And (remember) when your Lord proclaimed: ‘If you give thanks (by accepting Faith and worshipping none but Allah), I will give you more (of My Blessings); but if you are thankless (i.e. disbelievers), verily, My punishment is indeed severe.’} [Ibrahim 14:7]
For more details, please see the following answers:
How to Increase Provision
How to Overcome Fear of Losing Means of Provision
The connection between provision and death
The Hadith: “Whoever is content with a little provision from Allah…”
And Allah knows best.