Ghaib or ghayb ( Arabic: غيب) is (the) unseen and unknown, in reference to Allah and the forces that shape the world. Believing in the unseen is a vital part of being a muslim as a believer cannot see, touch, feel or hear his Lord but must have faith in all that is said in the Quran. Allah swt chooses to keep al ghayb to himself up until the day of judgement when all shall be revealed to us, the heavens, the hell, the unknown.
Say: “No one in the heavens and the earth knows the unseen but Allah; and they do not know when they shall be raised.” [27:65]
The Prophet (a.s.) only knew that much Al-Ghaib which was revealed to him in the Quran. See the following verse:
These are announcements relating to the unseen which We reveal to you, you did not know them– (neither) you nor your people– before this; therefore be patient; surely the end is for those who guard (against evil).[11:49]