Yavorsky was born in
Jaworów,
Ruthenian Voivodeship of
Poland (now in
Ukraine). He enrolled in the
Kyiv-Mohyla Academy around 1673 and completed its course of study; in 1684 he traveled back to Poland to continue his education, at which point he was compelled to join the
Uniate church, as was common for Kievan students who wanted to study in the
Polish–Lithuanian Commonwealth; he took the Uniate name Stanislav (). He spent five years abroad, studying philosophy in
Lwów and
Lublin and theology in
Poznań and
Vilnius, where he completed his education. In 1689 he returned to Kiev, broke from the Uniate church and returned to Eastern Orthodoxy. He took monastic vows under the name Stefan and settled at the Kiev Academy as a preacher and professor, being appointed prefect of the institution and in 1697
hegumen of the Nikolaevsky monastery (). He also began to preach, which soon made him well known in Kiev. At the beginning of 1700 he visited Moscow on church business, and when the
boyar Aleksei Shein died in February
Patriarch Adrian commissioned him to give the eulogy, which attracted the attention of Peter I, who was so pleased he had Yavorsky remain in Moscow and ordered a position to be found for him, as a result of which he was made
archbishop of
Ryazan and
Murom in April. When Adrian himself died in October, Yavorsky was appointed
locum tenens of the patriarchal see. "Thus in the course of seven months Iavorsky ascended from the humble position of father superior to the highest office in the entire church. Iavorsky had never desired such an appointment and even attempted to avoid it, but Peter was unyielding [because] the prelate was not a progressive or a reformer, but he was an authoritative figure with a European education, of which there were still few in Russia". Yavorsky's life now changed dramatically. He lived in Moscow, Saint Petersburg, and Ryazan, returning to Ukraine only rarely and with the express permission of the tsar. As the head of the church, he had to deal with the struggles between the various factions in the church, and he was expected to uphold Peter's reforms. At first he did so, but eventually the reforms restricted the rights of the church that he began to oppose them, and in 1712 a sermon of his, calling the
Tsarevich Alexei "Russia's only hope" and hinting at criticism of the tsar's personal life, so angered Peter that he forbade Yavorsky to preach in public. Yavorsky directed a commission on correcting the translation of the Bible and wrote
The Rock of Faith (), a huge treatise on dogma that "was sharply anti-Protestant in spirit" and whose publication Peter forbade (it was published in 1728 under
Peter II). In 1721 he was made first president of the newly erected
Holy Synod, but the real power was held by its vice president, Peter's close collaborator
Theophan Prokopovich. When Yavorsky died in the following year, Prokopovich took his place as president; shortly before his death, suspected of being involved in a publication that accused Peter of being the
Antichrist, he was interrogated in his home by members of the Synod and
Senate, and "it is possible that only his death saved Iavorsky from punishment". ==Literary activity==