▁Saf avid ▁dynast y ▁arose ▁to ▁renew ▁the ▁state ▁of ▁Pers ia ▁and ▁establish ▁Sh i ' ism ▁as ▁the ▁official ▁religion ▁of ▁Iran . ▁Ar ound ▁the ▁same ▁time , ▁the ▁population ▁of ▁what ▁is ▁now ▁A zer ba ij an ▁and ▁Iran ▁were ▁converted ▁to ▁Sh i ism , ▁and ▁both ▁nations ▁remain ▁the ▁only ▁nations ▁in ▁the ▁world ▁with ▁a ▁significantly ▁Sh ia ▁majority , ▁with ▁Iran ▁having ▁the ▁largest ▁Sh ia ▁population ▁by ▁percentage , ▁with ▁the ▁Republic ▁of ▁A zer ba ij an ▁having ▁the ▁second ▁largest ▁Sh ia ▁population ▁by ▁percentage . ▁ ▁After ▁ 1 5 0 2 , ▁A zer ba ij an ▁became ▁the ▁chief ▁bul w ark ▁and ▁military ▁base ▁of ▁the ▁Saf av ids . ▁It ▁was ▁the ▁chief ▁province ▁from ▁which ▁the ▁various ▁Iran ian ▁emp ires ▁would ▁control ▁their ▁C au cas ian ▁provinces , ▁all ▁the ▁way ▁up ▁to ▁D ag est an ▁in ▁the ▁early ▁ 1 9 th ▁century . ▁In ▁the ▁meant ime , ▁between ▁ 1 5 1 4 ▁and ▁ 1 6 0 3 , ▁the ▁Ott om ans ▁sometimes ▁occupied ▁Tab riz ▁and ▁other ▁parts ▁of ▁the ▁province ▁during ▁their ▁numerous ▁wars ▁with ▁their ▁Saf avid ▁ide ological ▁and ▁political ▁arch rival s . ▁The ▁Saf avid ▁control ▁was ▁restored ▁by ▁Shah ▁Abb as ▁but ▁during ▁the ▁Afghan ▁invasion ▁( 1 7 2 2 – 8 ) ▁the ▁Ott om ans ▁re capt ured ▁A zer ba ij an ▁and ▁other ▁western ▁provinces