The modern Persian name of Iran (ایران) derives immediately from 3rd-century Sassanian Middle Persian ērān (Pahlavi spelling: ʼyrʼn), where it initially meant "of the Iranians", but soon also acquired a geographical connotation in the sense of "(lands inhabited by) Iranians". In both geographic and demonymic senses, ērān is distinguished from its antonymic anērān, meaning "non-Iran(ian)".
In the geographic sense, ērān was also distinguished from ērānšahr, the Sassanians' own name for their empire, and which also included territories that were not primarily inhabited by ethnic Iranians.
The word ērān is first attested in the inscriptions that accompany the investiture relief of Ardashir I (r. 224–242) at Naqsh-e Rustam. In this bilingual inscription, the king calls himself ardašīr šāhān šāh ērān in Middle Persian, and ardašīr šāhān šāh aryān in Parthian. Both mean "Ardashir, king of kings of the Iranians". The Middle Iranian ērān/aryān are oblique plural forms of gentilic ēr- (Middle Persian) and ary- (Parthian), which in turn both derive from Old Iranian *arya-, meaning "'Aryan,' i.e., 'of the Iranians.'" This Old Iranian *arya- is attested as an ethnic designator in Achaemenid inscriptions as Old Persian ariya-, and in Zoroastrianism's Avesta tradition as Avestan airiia-/airya, etc. It is "very likely" that Ardashir I's use of Middle Iranian ērān/aryān still retained the same meaning as did in Old Iranian, i.e. denoting the people rather than the empire.