late 14c., "act of dwelling in a place; one's dwelling place," from Old French residence, from Medieval Latin residentia (source also of Spanish residencia, Italian residenza), from Latin residentem (nominative residens) "residing, dwelling," present participle of residere "to settle, linger, sit down" (see reside).
Meaning "fact of having one's usual abode in a particular place" is from late 15c. The sense of "a staying in some place for the discharge of special duties or one's occupation" is also from late 14c., originally ecclesiastical, extended 19c. to professors, artists, poets, etc. The expression _____-in-residence is attested by 1954. Also borrowed into German (Residenz), Dutch (residentie).