 Born in Travnik in the Austrian Empire, modern-day Bosnia, Andrić attended high school in Sarajevo, where he became an active member of several South Slav national youth organizations.Following the assassination of Archduke Franz Ferdinand in June 1914, Andrić was arrested and imprisoned by the Austro-Hungarian police, who suspected his involvement in the plot.As the authorities were unable to build a strong case against him, he spent much of the war under house arrest, only being released following a general amnesty for such cases in July 1917.