Allusions in rabbinic literature to the Biblical story of Daniel contain various expansions, elaborations and inferences beyond the text presented in the Book of Daniel. These stories are describing Jewish success in the Diaspora, where it was important to emphasize Jewish wisdom and statecraft during periods of foreign domination in order to strengthen the sense of worth and ethnic pride of the Jewish people.
According to rabbinical tradition Daniel was of royal descent; and his fate, together with that of his three friends, Hananiah, Mishael, and Azariah, was foretold by the prophet Isaiah to King Hezekiah in these words, "and they shall be eunuchs in the palace of the king of Babylon".
According to this view, Daniel and his friends were eunuchs, and were consequently able to prove the groundlessness of charges of immorality brought against them, which had almost caused their death at the hands of the king. It was said of Daniel, "If he were in one scale of the balance and all the wise men of the heathens in the other, he would outweigh them all".
Nebuchadnezzar admired Daniel greatly, although Daniel refused the proffered divine honors, thus distinguishing himself favorably from the contemporary ruler of Tyre, who demanded honor as a god.
The rabbis had difficulty reconciling Daniel's concern and apparent friendliness towards the man who had destroyed the Temple. They handled this in two ways. When Daniel explains to Nebuchadnezzar the dream of the tree that was cut down, the rabbis viewed it in the context of Isaiah 56:1, which is sometimes rendered "Do what is right, and give alms." The midrash explains that Daniel advised him to atone for his sins by good deeds, and for his misdeeds by kindness to the poor. This was because Daniel knew that many of the Jewish exiles were starving.
When Daniel says, "My lord, this dream should be for your enemies, and its meaning for your foes," the rabbis conclude that this is addressed to God, rather than king Nebuchadnezzar; otherwise it could be interpreted as favoring Nebuchadnezzar over Israel.
No names of angels are mentioned in the Bible until the Book of Daniel, where Michael and Gabriel make their appearance. This led the Rabbis to assert that the names of the angels were something that the returning exiles brought with them from Babylonia. Gabriel was believed to have been the angel who delivered Hananiah, Mishael, and Azariah from the fiery furnace.
Daniel denied himself much in the matter of food, since he would not partake of the wine and oil of the heathens. Daniel was not forced, as were his three friends, to worship the idol which Nebuchadnezzar set up; for the king, who well knew that Daniel would rather be cast into the fiery furnace than commit idolatry, sent him away from Babylon so he would not be forced to condemn him. Furthermore, it was God's intention to cause the three men to be taken out of the furnace during the absence of Daniel, so that their rescue should not be ascribed to the merit of the latter.
Nevertheless, the king endeavored to induce Daniel to worship the idol, by trying to make him believe that it was alive and real. He ordered that there be placed in its mouth the frontlet (tzitz) of the high priest, on which was written the name of God; and since this name possessed the miraculous power of enabling inanimate things to speak, the idol could utter the words "I am thy god." Daniel, however, was not to be so easily deceived. Asking permission to kiss the idol on the mouth, he stepped before it and conjured the frontlet in the following words: "Although I am only a man of flesh and blood, yet I stand here as God's messenger. Take care that God's name is not desecrated by you, and thus I command you to follow me." While he was kissing the idol, the frontlet passed from the idol's mouth into his. When Nebuchadnezzar, as usual, sent for musicians to give songs of praise to the idol, he noticed that Daniel had silenced it.
Daniel's success at court naturally excited the envy and ill will of the Babylonians, who gathered in a mob and threatened the king and his house if he did not deliver Daniel to them. The king was powerless to resist, and the people took Daniel and threw him into a den with seven famished lions. Daniel remained there unharmed for six days, being fed during that time by the prophet Habakkuk, whom an angel had in an instant transported from Judea to Babylon, holding him by the hair of his head. On the seventh day the king went to the den to bewail Daniel, and was astonished to find him alive.
Although Daniel was not forced to sin in any way, he was prepared to sacrifice his life rather than omit his prayers; hence it was easy for his enemies to convict him of having violated the royal order. While he was at prayer his enemies entered his room, and watched to see whether the accusations against him could be substantiated, as the king did not believe them. Daniel did not omit his Mincha prayer. Despite his friendship for Daniel, the king listened to the nobles' accusations, and condemned Daniel to be cast into the den of lions. The mouth of the den was closed with a huge stone, which had rolled on its own from Palestine to Babylon for that purpose. Upon this stone sat an angel in the shape of a lion, so that Daniel's enemies might not harass him.
Daniel's enemies insisted that the lions were tame because they were not hungry, whereupon the king commanded that the accusers themselves spend a night with the beasts. As a result, the enemies of Daniel, numbering 122, with their wives and children, making a total of 366 persons, were torn by 1,469 lions.
Although Daniel was no prophet in the rabbis' opinion, God held him worthy to receive the revelation of the destiny of Israel, even to the Day of Judgment, thus distinguishing him from his friends, the prophets Haggai, Zechariah, and Malachi, who had no visions. Daniel, however, forgot the "end" revealed to him, after an angel had shown him everything.