Stephen Báthory ; 27 September 1533 - 12 December 1586) was Voivode of Transylvania , Prince of Transylvania , from 1576 Queen Anna Jagiellon's husband and jure uxoris King of Poland and Grand Duke of Lithuania . The son of Stephen VIII Báthory and a member of the Hungarian Báthory noble family, Báthory was a ruler of Transylvania in the 1570s, defeating another challenger for that title, Gáspár Bekes. In 1576 Báthory became the third elected king of Poland. He worked closely with chancellor Jan Zamoyski. The first years of his reign were focused on establishing power, defeating a fellow claimant to the throne, Maximilian II, Holy Roman Emperor, and quelling rebellions, most notably, the Danzig rebellion. He reigned only a decade, but is considered one of the most successful kings in Polish history, particularly in the realm of military history. His signal achievement was his victorious campaign in Livonia against Russia in the middle part of his reign, in which he repulsed a Russian invasion of Commonwealth borderlands and secured a highly favorable treaty of peace .. Who was born first: Stephen VIII Báthory or Stephen Báthory?