On 28 June 1914 Gavrilo Princip participated in the assassination in Sarajevo. General Oskar Potiorek, Governor of the Austrian provinces of Bosnia and Herzegovina had invited Franz Ferdinand and Countess Sophie to watch his troops on manoeuvres. Franz Ferdinand knew that the visit would be dangerous, knowing his uncle, Emperor Franz Josef, had been the subject of an assassination attempt by the Black Hand in 1911.
Just before 10 o'clock on Sunday, the royal couple arrived in Sarajevo by train. In the front car was Fehim Čurčić, the Mayor of Sarajevo and Dr. Gerde, the city's Commissioner of Police. Franz Ferdinand and Sophie were in the second car with Oskar Potiorek and Count Friedrich August von Harrach-Rohrau. The car's top was rolled back in order to allow the crowds a good view of its occupants.
The seven conspirators lined the route. They were spaced out along the Appel Quay, each one with instructions to try to kill Franz Ferdinand when the royal car reached his position. The first conspirator on the route to see the royal car was Bosniak Muhamed Mehmedbašić. Standing by the Austro-Hungarian Bank, Mehmedbašić lost his nerve and allowed the car pass without taking action. Mehmedbašić later said that a policeman was standing behind him and feared he would be arrested before he had a chance to throw his bomb.
At 10:15 A.M., when the six car procession passed the central police station, nineteen-year-old student Nedeljko Čabrinović hurled a hand grenade at the Archduke's car. The driver accelerated when he saw the object flying towards him, but the bomb had a 10 second delay and exploded under the wheel of the next car. Two of the occupants, Eric von Merizzi and Count Ludwig Joseph von Boos-Waldeck were seriously wounded. About a dozen spectators were also hit by bomb splinters.
After Čabrinović's bomb missed the Archduke's car, five other conspirators, including Princip, lost an opportunity to attack because of the heavy crowds and the high speed of the Archduke's car. To avoid capture, Čabrinović swallowed cyanide and jumped into the River Miljacka to make sure he died. The cyanide pill was very old and made him sick, but failed to kill him and the River Miljacka was only 13 centimetres (5 in) deep. A few seconds later he was hauled out and detained by police. A map depicting the assassination route.
Franz Ferdinand later decided to go to the hospital and visit the victims of Čabrinović's failed bombing attempt. In order to avoid the city centre, General Oskar Potiorek decided that the royal car should travel straight along the Appel Quay to the Sarajevo Hospital. However, Potiorek forgot to inform the driver, Leopold Loyka, about this decision. On the way to the hospital, Loyka took a right turn into Franz Josef Street.
Princip had gone into Moritz Schiller's cafe for a sandwich, having apparently given up, when he spotted Franz Ferdinand's car as it drove past, having taken the wrong turn. After realizing the mistake, the driver put his foot on the brake, and began to back up. In doing so the engine of the car stalled and the gears locked, giving Princip his shot. Princip stepped forward, drew his FN Model 1910 pistol, and at a distance of about five feet, fired twice into the car. Franz Ferdinand was hit in the neck and Sophie in the abdomen, and they both died before 11:00 A.M.