Avot D’Rabbi Natan 25:3
When Rabbi Eliezer became sick, (they say) it was the eve of the Sabbath. Rabbi Akiva and his companions came in to visit him. He was sleeping in his room, so they sat in the entrance hall. His son Hyrcanus went in to take off his father’s tefillin,1It was right before the Sabbath, and tefillin are not worn on the Sabbath. but his father would not let him, and began to cry. Hycanus came out and said to the sages: My masters, it seems to me that my father is confused. But his father called out: My son, I am not confused – you are confused! For you have not lit the Sabbath candles, for which you can be sentenced to death by divine decree. But I was just wearing tefillin, which is forbidden [to be worn on the Sabbath] only by rabbinic practice. When the sages saw that he was of clear mind (they went in) and sat before him, at a distance of four cubits. They said to him: Rabbi, a circular cushion, a ball, a mannequin, an amulet, and a torn prayer box – what is their status (with regard to whether they can become impure)? He said to them: They can become impure, and you should immerse them in water just as they are. Be very careful to do this, because these are important laws that were said to Moses on Mount Sinai. So they continued asking about ritual purity and impurity, and immersions. They would say: Rabbi, what about this? And he would say: Impure. What about that? And he would say: Pure. In this way he answered all their questions about what was pure and what was impure.
Afterward, Rabbi Eilezer said to the sages: I wonder if the students of this generation will be punished by death at the hands of Heaven. They replied: Rabbi, why? He said to them: Because they have not come and apprenticed with me.
Then he said to Akiva ben Yosef: Akiva, why did you not come to apprentice with me? Rabbi Akiva said: I did not have any time to come. He replied: I wonder if you will die a natural death.
Some say they never said any of this; rather, when Rabbi Eliezer first said this about the students, Akiva’s blood started racing inside of him, and he said: And Rabbi, how will I die? And Rabbi Eliezer said: (Rabbi) Akiva, your death will be the worst of all. Then Rabbi Akiva went and sat before him and said: Rabbi, teach me. Rabbi Eliezer began by teaching him three hundred laws about impure white patches of skin [baheret]. Then Rabbi Eliezer raised both of his arms and lay them on his chest, and said: Oy, these two arms of mine are like two Torah scrolls that will vanish from the world! For if all the seas were ink, and all the reeds were quills, and every person was a scribe, they still could not write down everything that I have read and taught. I apprenticed with the sages in the academy and did not forget (a thing I witnessed), not even a drop out of the sea. I never ceased learning except to dip my quill into ink. I could teach three hundred laws just on the verse, “Do not let a witch live” (Exodus 22:17) – and some say it was three thousand laws! – But no one ever asked me about them except for Akiva ben Yosef, who once said, Rabbi, teach me how they plant squash [through witchcraft], (and how we uproot them). And I answered, With one word, the whole field is filled with squash. So he said to me, Rabbi, you have taught me about how they are planted; now teach me about how they are uprooted. And I said, With one word, they can all be gathered together into one place.
Rabbi Elazar ben Azariah said to him: Rabbi, what about a sandal on a mannequin’s leg? He answered: Pure. In this way he kept answering questions about what was pure and what was impure, until his soul departed in a state of purity. Immediately, Rabbi Elazar ben Azariah tore his clothes and wept. Then he went out and said the sages: My Masters, come and see Rabbi Eliezer, who will be pure in the World to Come (because) his soul left in a state of purity.
After the Sabbath, Rabbi Akiva came and found Rabbi Eliezer being taken in a coffin from Caesarea to Lod. Immediately, he tore his clothes and pulled at his hair until blood began to come out and drip onto the ground. And he screamed and cried and said: Woe is me, my master, for I have lost you! Woe is me, my master, for I have lost you! My master, you have left this whole generation like an orphan! At the head of his funeral line, he said, “My father, my father, the chariot of Israel and all its horsemen!” (II Kings 2:12). You have left money for me, and I have no table [i.e., money changer] to exchange them.