Date: 202005
Local time of day: 1201-1800
Location: ZZZZ.ARTCC, FO
Flight conditions: VMC
Light: Daylight
Aircraft: B747-400
Operator: Air Carrier
Operating under: Part 121
Flight plan: IFR
Mission: Cargo / Freight / Delivery
Flight phase: Cruise
ATC / advisory: Center ZZZZ
Reporter organization: Air Carrier
Reporter function: First Officer; Pilot Not Flying; Relief Pilot
Reporter qualification: Flight Crew Air Transport Pilot (ATP); Flight Crew Instrument; Flight Crew Multiengine
Second reporter function: Pilot Flying; First Officer
Anomaly: Flight Deck / Cabin / Aircraft Event Illness / Injury
Detector: Person Flight Crew
When detected: In-flight
Result: Air Traffic Control Provided Assistance; Flight Crew Diverted; General Physical Injury / Incapacitation
Contributing factors: Staffing
Primary problem: Staffing

Narrative: We departed from ZZZ uneventfully enroute to ZZZ1. I was sitting third seat and the Captain was the Pilot Flying. As previously agreed; myself and the First Officer in the fourth seat would take first break; so we went to the bunks after top of climb. About 4 hours into our break; I was awakened by a cockpit interphone call from the Flight Deck. Upon leaving the bunk; I observed the Captain lying on the floor of the upper deck in an unresponsive state; being attended to by some of the 4 deadheading crewmembers. The remaining deadheading crew were in the flight deck assisting the operating First Officer with the medical emergency. I inquired as to what was happening and was told that the Captain was in his seat in casual conversation when he became unresponsive and was removed from his seat and attended to by the other deadheading crewmembers.  I quickly informed the other operating First Officer ( who was also summoned from the other bunk) of the situation. I quickly got dressed and took station in the third seat relieving the deadheading crewmembers of their communication and coordination with company; ATC; and Medlink. The other Relief First Officer occupied the Captain's seat.  The crew was already diverting to the nearest suitable airport; ZZZZ; but based on the Captain's partial recovery; both Dispatch and Medlink recommended proceeding to ZZZ2 so we agreed and changed diversion airport to ZZZ2. Procedures were then carried out to proceed to ZZZ2 followed by an uneventful landing at ZZZ2.


Second narrative: While in cruise; after what appeared to be a medical event; the Captain became unresponsive. I assumed Pilot Flying duties while the other crew members; DH and operating; helped remove the Captain from his station. I [advised medical with ATC] and chose to divert to the nearest suitable airport ZZZZ. After some amount of time; the Captain became responsive again and did not appear to be in any immediate danger. After contacting Medlink; Dispatch; and the [Chief Pilot]; the crew agreed to change our diversion airport to ZZZ2; about an hour further than ZZZZ. The weather at ZZZ2 was CAVOK with light winds. The senior operating First Officer occupied the Captain's station and assumed Pilot Monitoring duties. The crew agreed that the landing should be made from the right seat. The approach; landing; taxi; and parking at ZZZ2 was uneventful.


Synopsis: B747 flight crew reported that the Captain became unresponsive; causing the crew to divert.