1784, "descent of a Hindu deity to earth in an incarnate or tangible form," from Sanskrit avatarana "descent" (of a deity to the earth in incarnate form), from ava- "off, down" (from PIE root *au- (2) "off, away") + base of tarati "(he) crosses over," from PIE root *tere- (2) "cross over, pass through, overcome."
Meaning "concrete embodiment of something abstract" is from 1815. In computer use, it seems to trace to the novel "Snowcrash" (1992) by Neal Stephenson.