It is obvious that Hafez poetry is completely affected by the Quran in its words, expressions, phrases, structure and style. This has made his word symbolic, ambiguous, multilayer in content, and artistic. His fifth sonnet has been inspired by the story of Moses and Abd (Khedhr) in the Quran. He must have consciously and skillfully got use of the plot of the story and combined it with the elements of Persian poetry. Key words and phrases making the reader of the sonnet associate them with the verses from the Quran including ‘unveiling the mystery’, ‘wrecked ship’, ‘visiting the familiar one’, ‘the man of poverty’, ‘struggle for joy and pleasure’, ‘getting addict by wine’, and begging apology’ directly or indirectly are the signs and symbols whose compatibility with the content of the verses 62 and 82 in the Surah of Kahf (cave) the author tries to examine.