The 11th of the Rambam’s 13 Principles of Judaism is the belief in divine reward and retribution.
HaShem rewards one who lives up to the mitzvot of the Torah and punishes those who breaks the rules. The greatest reward is [experiencing] Olam HaBa -- the World to Come.
The greatest punishment is to be כרת / kareit -- cut off – from G-d and the Jewish people. Sh’mot / Exodus 32:32-33 tells us: “Now, if You would, please forgive their sin. If not, You can blot me out from the book that You have written.” Being blotted out is an allegory meaning, 'erase me from Your memory' (Moreh Nevukhim 2:47), or, 'blot me out from all creation' (Ralbag). G-d replied to Moses “I will blot out from My book those who have sinned against Me.” Those who are cut off from G-d are “blotted out.”
Reward and punishment does not equal the need to be perfect, or to perfectly observe all of the pertinent mitzvot. "there is no righteous man on earth who does good who never sins.” Kohelet / Ecclesiastics 7:20. Righteous people sin – everyone sins (makes mistakes, or even does bad things intentionally). The question is, do you learn from your mistakes, repent, seek forgiveness (from those you wronged and G-d) and try to be a better person?
To be כרת / kareit -- cut off from G-d, is very rare. It is even rarer in the world today as many people do not know what is expected of them. G-d judges us not only with mercy, but He judges us based on who we are (our personal abilities and limitations as well as our understanding of what He expects from us).
Can you reverse sins and wrongdoings by performing more mitzvot?
Torah says “no.” Performing an unrelated mitzvah will not correct our wrong in another area. “A mitzvah does not atone for a sin”. (Sh’mot / Exod. 32:33). If you’ve done something wrong – intentionally or not – you must atone for THAT wrongdoing. We cannot avert G-d’s punishments with unrelated activities, or even with unrelated mitzvot.
We study Torah for our own perfection, not for any worldly benefit we might derive from it. The purpose of the mitzvot are to make us a better and holier person – to grow spiritually. This is the reward! Learning the Torah is done for its own sake. It means that the end of studying wisdom should be for the sake of knowing it. The truth has no other purpose than knowing that it is the truth. Since the Torah is truth, the purpose of knowing it is to do it.
The Rambam goes on to say “Our sages have warned us about this. They said that one should not make the goal of one’s service of G-d or of performing the mitzvot anything in the world of things.” A person who does so serves G-d not out of love but out of duty. The Rambam then quotes the Talmud that the person who desires G-d’s mitzvot and not reward is the true servant of G-d.
In other words, the mitzvot are themselves a reward and to fulfill them out of trust and devotion to G-d is its reward. The true delight is spiritual. Such delight has no physical analogy, it is on a completely different dimension. Individuals who purify themselves in this world through Torah study and performing mitzvot achieve spiritual heights (the reward) and this is the entire purpose of our creation (to grow spiritually).
In Olam HaBa (the world to come) those who have grown spiritually are able to bask in the divine presence. To explain this I’ll use an analogy. Think of G-d and heaven in terms of music. G-d’s orchestra plays the finest symphonies ever created. To one who understands classical music it is the most beautiful sound they ever heard. They truly appreciate it and love it. But to one who has a tin ear, who has never liked music (or perhaps likes modern “rap” music) the sound of the symphony is painful to their ears. Both souls hear the same sound – but it is very different to each of them.
For the one who grows spiritually, the reward is, well, rewarding. To the one who has not earned the reward it may well be punishment. The very same existence.
The Rambam says that the reward of the righteous in Olam HaBa is the existence of the soul thanks to what it has learned in this world. The existence is blissful because it involves the cognition of G-d on a plane that most could never comprehend. The final end of humans consists of knowing G-d. This knowledge is the cause of the soul’s continued existence.
Reward in Olam HaBa is a consequence of achieving a level of holiness in this world.
If that is the reward, what is the punishment?
The cutting off of the soul so that it ceases to exist. There is no hell in Judaism (no eternal torment as in Christianity). Judaism is somewhat silent on what happens when we die – or when it happens (do people who die sleep until the messiah comes, or do they go to a place of reward (Gan Eden / Heaven), or do they go to a place of purification to learn what they did wrong (Gehenna) or do they become reincarnated to “try again” to get it right? There are various schools of thought.
To the worst possible sinner their individual soul (which is pure and cannot sin) returns to G-d who removes its individuality. It simply ceases to exist as an individual consciousness. The Talmud tells us this is very, very rare.
To summarize – Jews are obligated to fulfill the 613 mitzvot (and non-Jews the 7 mitzvot). It is good for us to do so, we grow spiritually through them. There is no direct “quid pro quo” compensation for fulfilling the mitzvot. The “compensation” is the spiritual growth we gain by fulfilling them out of love with no expectation of reward. Torah is its own reward. The mitzvot are preparations which enable us to achieve intellectual and spiritual growth which is fully realized in Olam HaBa (the world to come).
It is for this reason that humans are born with the potential to learn. We are born with a capacity to know G-d and by learning the truth (Torah) we become truly human – we have acquired our intellects, we have actualized our potential.
What about modern Jews who are raised secular, or in another religion? What about Jews who are raised unaware of their duties to the mitzvot who, G-d forbid, convert themselves to Christianity or another faith? The Rambam excludes them from those who deserve such punishment because they participated unwittingly in their denial of Torah and mitzvot. While they are indeed sinners, he declares them unintentional participants in their lack of adherence to Jewish law and belief, similar to the case of a tinok shenishba (like one kidnapped as a child and raised unaware of Torah). The Rambam states that we try to bring them back to Judaism and embrace them into the Jewish community, teaching them the mitzvot so they can become observant, pious members of community. Today’s Chabad and Aish HaTorah kiruv (outreach) programs are based on exactly this philosophy. (Read the Rambam’s Mishneh Torah, Hilchot Mamrim 3:3 for more information).