The main theme of this chapter is to warn the people and give them glad tidings, as shown by its starting verses and its five ending verses. To do so, it discusses some parts of the stories of Prophets Moses, David, Solomon, Salih and Lot. Then it continues by addressing some fundamental religious teachings such as the unity of God in Lordship, and the Resurrection.
There are five stories discussed in this chapter and are presented as evidence for the glad tidings and warnings that were mentioned at the beginning of the chapter. The first three stories emphasize glad tidings, while the last two stories emphasize warnings.
The story of prophet Solomon includes some wonders about the kingdom that God gave Solomon.
After presenting a sample of stories that God recounted about His consistent custom regarding humankind, God makes a transition from those stories to praising Himself and sending peace upon His chosen servants. He explains that only He is worthy of worship, not any of the partners that the people associate with Him. Then He moves on to discuss His oneness, the truth of the hereafter, and other relevant beliefs. Thus the flow of the verses in the chapter is comparable to the flow of the verses in Chapter 19 (Maryam).
The chapter concludes by talking about the Resurrection, the events after it, and some of its signs. Then the chapter ends as it started: by warning and giving glad tidings.