late Old English, "twisted, crooked, wry," from Old Norse rangr, earlier *vrangr "crooked, wry, wrong," from Proto-Germanic *wrang- (source also of Danish vrang "crooked, wrong," Middle Dutch wranc, Dutch wrang "sour, bitter," literally "that which distorts the mouth"), from *wrengh-, nasalized variant of *wergh- "to turn," from PIE root *wer- (2) "to turn, bend."
Sense of "not right, bad, immoral, unjust" developed by c. 1300. Wrong thus is etymologically a negative of right (adj.1), which is from Latin rectus, literally "straight." Latin pravus was literally "crooked," but most commonly "wrong, bad;" and other words for "crooked" also have meant "wrong" in Italian and Slavic. Compare French tort "wrong, injustice," from Latin tortus "twisted."
As an adverb from c. 1200. Wrong-headed is recorded by 1732. To get up on the wrong side (of the bed) "be in a bad mood" is recorded from 1801, according to OED, from its supposed influence on one's temper; it appears in Halliwell's "Dictionary of Archaic and Provincial Words" in 1846, but doesn't seem to have been used much generally before late 1870s. To rise on the right side (of the bed) is proverbial by 1560s indicating either good luck or a good disposition. To be on the wrong side of a given age, "older than," is from 1660s. Wrong side of the road (that reserved for oncoming traffic) is by 1838. To be from (or on) the wrong side of the tracks "from the poor part of town" is from 1921, American English.
"that which is improper or unjust," late Old English, from wrong (adj.). Meaning "an unjust action" is recorded from c. 1200. Wrong-doer is from late 14c.