The donkey of Rabbi Pinehas ben Yair was as righteous as its master — or so the Talmud (Jerusalem Talmud Demai 1:3, Hullin 7a-b) suggests through a story that became one of the most beloved animal tales in rabbinic literature.
The donkey was once stolen by thieves who kept it in their hideout. For three days, the animal refused to eat. The thieves offered it grain, barley, straw — everything a donkey should devour. It touched nothing.
"Why should we keep a beast that will not eat?" the thieves reasoned. "It will die and contaminate our hiding place with the stench." So they released it. The donkey trotted straight home to Rabbi Pinehas.
When it arrived, Rabbi Pinehas set food before it. Again, it refused to eat. His students were puzzled — the donkey was clearly starving after three days without food. Why would it not eat now that it was home?
Rabbi Pinehas asked: "Have you tithed the grain?" They had not. The moment the grain was properly tithed, the donkey ate.
The sages marveled: even the animals belonging to the righteous are held to a higher standard. Rabbi Pinehas ben Yair's holiness was so pervasive that it affected his livestock. His donkey would not eat stolen food among thieves, and it would not eat untithed food at home.
The story carried a pointed lesson: if a donkey can refuse forbidden food, what excuse does a human being have? If an animal's instinct can be overridden by the holiness of its owner, surely a person's appetites can be mastered by their own will.