Intro: Why do bad things happen to good people? Read on some of the classic answers and some lesser known answers as the rabbis and philosophers struggle to answer the question of theodicy.
And herein is resolved the great dilemma in G-d's conduct of the world: "the righteous man who suffers, and the wicked man who prospers." For if the heavenly influences manifesting themselves in this terrestrial world were all specific, so that one star would attach to one man alone, the Blessed One assigning it to him individually to compensate him in accordance with his deeds, this would, indeed, be cause for wonder. But this is not the case, for the ordinance of the terrestrial world is generic, so that it is impossible to expect continuous good uninterrupted occasionally by evil.
This would be analogous to expecting the sun to ripen grain and fruits and not beat down on the head of the righteous man walking on the road in the period of Tammuz so that he not contract the illness to which he is thus predisposed.
In the same way, when a certain malignant influence is released upon a place or clime, it will not manifest itself as the Blessed One's striking with rod or thong only specific individuals but as a generic maleficent force, which will cause injury even to him who does not deserve to be punished by it, unless his merit be so great that the Blessed One save him through an alteration of nature.
אלו שני דורות זכה משלימין לו לא זכה פוחתין לו דברי ר' עקיבא וחכמים אומרים זכה מוסיפים לו לא זכה פוחתין לו אמרו לו לרבי עקיבא
If one is worthy one is allowed to complete the full period of their life; if unworthy the number is reduced; so said R. Akiba.
But the Sages said: If one is worthy, years are added to one's life; if unworthy, the years of his life are reduced.
רב חסדא חיה תשעין ותרתין שנין רבה חיה ארבעין בי רב חסדא שיתין הלולי בי רבה שיתין תיכלי
בי רב חסדא סמידא לכלבי ולא מתבעי בי רבה נהמא דשערי לאינשי ולא משתכח
[Rav Hisda and Rabba were both very holy. But their lives looked very different]...
Rav Ḥisda lived for ninety-two years, whereas Rabba lived for only forty years.
The house of Rav Ḥisda celebrated sixty wedding feasts, whereas the house of Rabba experienced sixty calamities.
In the house of Rav Ḥisda there was bread from the finest flour [semida] even for the dogs, and it was not asked after, as there was so much food. In the house of Rabba, on the other hand, there was coarse barley bread even for people, and it was not found in sufficient quantities.
This shows that the length of life, children, and sustenance all depend not upon one’s merit, but upon fate.
Mahzor
ותשובה ותפלה וצדקה מעבירין את רע הגזרה
But repentance, prayer and charity cancel the evil decree.
Perhaps another way to understand what happens to people is that we all get disconnected from God from time to time. Only if we are constantly connected can we be assured protection from the general maleficent forces in life:
רב חסדא לא הוה יכיל ליה דלא הוה שתיק פומיה מגירסא סליק יתיב בארזא דבי רב פקע ארזא ושתק ויכיל ליה
The Angel of Death was unable to take Rav Ḥisda because his mouth was never silent from study.
So the Angel of Death went and sat on the cedar column that supported the roof of the study hall of the Sages.
The cedar cracked and Rav Ḥisda was silent for a moment, as he was startled by the sound. At that point the Angel of Death was able to take him.
(7) We must bear in mind that all such religious acts as reading the Law, praying, and the performance of other precepts, serve exclusively as the means of causing us to occupy and fill our mind with the precepts of God, and free it from worldly business; for we are thus, as it were, in communication with God, and undisturbed by any other thing.
If we, however, pray with the motion of our lips, and our face toward the wall, but at the same time think of our business; if we read the Law with our tongue, whilst our heart is occupied with the building of our house, and we do not think of what we are reading; if we perform the commandments only with our limbs, we are like those who are engaged in digging in the ground, or hewing wood in the forest... we are then like those in reference to whom Scripture says, "Thou art near in their mouth, and far from their reins" (Jer. 12:2).
(12) An excellent idea presents itself here to me, which may serve to remove many doubts, and may help to solve many difficult problems in metaphysics. We have already stated in the chapters which treat of Divine Providence, that
Providence watches over every rational being according to the amount of intellect which that being possesses. Those who are perfect in their perception of God, whose mind is never separated from Him, enjoy always the influence of Providence.
But those who, perfect in their knowledge of God, turn their mind sometimes away from God, enjoy the presence of Divine Providence only when they meditate on God; when their thoughts are engaged in other matters, divine Providence departs from them.
(13) Hence it appears to me that it is only in times of such neglect that some of the ordinary evils befall a prophet or a perfect and pious man... If man frees his thoughts from worldly matters, obtains a knowledge of God in the right way, and rejoices in that knowledge, it is impossible that any kind of evil should befall him while he is with God, and God with him. When he does not meditate on God, when he is separated from God, then God is also separated from him; then he is exposed to any evil that might befall him; for it is only that intellectual link with God that secures the presence of Providence and protection from evil accidents... And there is undoubtedly no difference in this regard between one single person and a whole community.