Thawban was a slave who had been freed by the Prophet (pbuh) and such was his love and gratitude towards Muhammad (pbuh) that he would have to see him every single day. Just by looking at his face, Thawban would feel his faith soar.
It occurred one day that Thawban didn’t see the Prophet (pbuh) until later in the day and he looked so sad and unhappy. When the Prophet (pbuh) questioned him he said that such was his love for the Prophet that he needed to see him each day. By not seeing him, Thawban was reminded that one day the Prophet would die and be admitted to the highest ranks of Jannah. This upset Thawban so much as he was afraid that he would not even be admitted to Jannah and therefore never see the Prophet (pbuh) again.
Then Jibril revealed the verses: And whoever obeys Allah and the Messenger will be in the company of those blessed by Allah: the prophets, the people of truth, the martyrs, and the righteous—what honourable company! Qur’an (4:69)
So if we wish to be with the Prophet (pbuh) in the Hereafter, all we need to do is love him and follow his sunnah.