Sahih al-Bukhari records that on the day of Khaybar the Prophet Muhammad ﷺ gave the banner to Ali ibn Abi Talib, may Allah be pleased with him, and that Allah granted victory through his hands. A separate report from Abu Rafi, preserved in Musnad Ahmad and al-Bayhaqi, says that during the fighting Ali lost his shield, took a door from the fortress, and used it as a shield until victory. The same report says that after Ali put the door down, Abu Rafi and seven other men tried to turn it over but could not. Other reports give larger numbers, but those are separate versions and are not merged into the Abu Rafi account here.
The account of the gate comes through a separate report from Abu Rafi. It says that while Ali was fighting near the fortress, his shield was knocked from his hand. In the middle of the battle he then took a door from the fortress and used it in place of his shield. He continued fighting with the door before him until Allah granted the Muslims victory.
After the fighting had ended, the report says that Ali threw the door down. Abu Rafi then describes what happened next: he and seven other men went to the door and tried to turn it over, but they were unable to do so. In this form of the story, the memorable moment is therefore not only Ali's use of the fortress door as a shield, but also the effort of eight men who later could not turn it.
This Abu Rafi account is preserved in Musnad Ahmad and is also found in al-Bayhaqi's Dala'il al-Nubuwwah. The report presents the event as part of the fighting at Khaybar and keeps the sequence compact: the shield is lost, the door is taken, Ali fights behind it, victory comes, and the door is later found difficult for the group of men to move.
Other classical reports tell related versions of the gate story with larger numbers. One version speaks of forty men, while another gives the number seventy. Those accounts have their own wording and transmission history, so they are not combined here with Abu Rafi's report. The present retelling keeps the eight-men detail attached only to the account in which Abu Rafi himself describes the aftermath.
Thus the public story remains focused on the clearest form of the narrated event: at Khaybar, Ali ibn Abi Talib, may Allah be pleased with him, is reported to have taken a fortress door after losing his shield, used it as protection while fighting, and then cast it down after the victory. Abu Rafi's report closes with eight men trying unsuccessfully to turn that same door.
Conclusion
The remembered karamah is the striking Khaybar scene in which Ali ibn Abi Talib, may Allah be pleased with him, is reported to have used a fortress door as a shield, while eight men later could not turn that door.