Old English swa, swæ (adv., conj., pron.) "in this way," also "to that extent; so as, consequently, therefore," and purely intensive; from Proto-Germanic *swa (source also of Old Saxon, Middle Dutch, Old High German so, Old Norse sva, Danish saa, Swedish så, Old Frisian sa, Dutch zo, German so "so," Gothic swa "as"), from PIE reflexive pronominal stem *swo- "so" (source also of Greek hos "as," Old Latin suad "so," Latin se "himself"), derivative of *s(w)e-, pronoun of the third person and reflexive (see idiom).
Old English swa frequently was strengthened by eall, and so also is contained in compounds as, also, such. The -w- was eliminated by contraction from 12c.; compare two, which underwent the same process but retained its spelling.
As a word confirming a previous statement, late Old English; also from late Old English as an intensive in an affirmative clause (such as so very "exceedingly, extremely"). As an "introductory particle" [OED] from 1590s. Used to add emphasis or contradict a negative from 1913. So in mid-20c. British slang could mean "homosexual" (adj.). So? as a term of dismissal is attested from 1886 (short for is that so?, etc.). So what as an exclamation of indifference dates from 1934. Abbreviating phrase and so on is attested from 1724. So far so good is from 1721.
parting salutation, 1860, of unknown origin, perhaps from a German idiom (compare German parting salutation adieu so lange, the full sense of which probably is something like "farewell, whilst (we're apart)"); or perhaps from Hebrew shalom (via Yiddish sholom). Some have noted a similarity to Scandinavian leave-taking phrases, such as Norwegian Adjø så lenge, Farvel så lenge, Mor'n så lenge, literally "bye so long, farewell so long, morning so long;" and Swedish Hej så länge "good-bye for now," with så länge "for now" attested since 1850 according to Swedish sources. Most etymology sources seem to lean toward the German origin. So long (adv.) "for such a long time" is from late Old English.
Earlier guesses that it was a sailors' corruption of a South Pacific form of Arabic salaam are not now regarded as convincing. "Dictionary of American Slang" also adds to the list of candidates Irish slán "safe," said to be used as a salutation in parting. The phrase seems to have turned up simultaneously in America, Britain, and perhaps Canada, originally among lower classes. First attested use is in title and text of the last poem in Whitman's "Leaves of Grass" in the 1860 edition.
An unknown sphere, more real than I dream'd, more direct, darts awakening rays about me — So long!
Remember my words — I may again return,
I love you — I depart from materials;
I am as one disembodied, triumphant, dead.
Whitman's friend and fan William Sloane Kennedy wrote in 1923:
The salutation of parting — 'So long!' — was, I believe, until recent years, unintelligible to the majority of persons in America, especially in the interior, and to members of the middle and professional classes. I had never heard of it until I read it in Leaves of Grass, but since then have quite often heard it used by the laboring class and other classes in New England cities. Walt wrote to me, defining 'so long' thus: "A salutation of departure, greatly used among sailors, sports, & prostitutes — the sense of it is 'Till we meet again,' — conveying an inference that somehow they will doubtless so meet, sooner or later." ... It is evidently about equivalent to our 'See you later.' The phrase is reported as used by farm laborers near Banff, Scotland. In Canada it is frequently heard; 'and its use is not entirely confined to the vulgar.' It is in common use among the working classes of Liverpool and among sailors at Newcastle-upon-Tyne, and in Dorsetshire. ... The London Globe suggests that the expression is derived from the Norwegian 'Saa laenge,' a common form of 'farewell,' au revoir. If so, the phrase was picked up from the Norwegians in America, where 'So long' first was heard. The expression is now (1923) often used by the literary and artistic classes.
"as if, as it were," used in introducing a proposed or possible explanation, late 15c., a Latin word used in Latin in hypothetical comparisons, "as if, just as if, as though;" in real comparisons "just as, as;" and in approximation, "somewhat like, nearly, not far from." It is from quam "as" relative pronominal adverb of manner (from PIE root *kwo-, stem of relative and interrogative pronouns) + si "if" (from PIE pronominal stem *swo- "so;" see so).
A parallel and earlier form in Middle English was howsomever (early 14c.), which survived through 18c. in provincial English and after that was counted a vulgar Americanism by English writers; it is the same compound but with the obsolete conjunction sum, from Old Norse sem "as, that" (cognate with Danish and Swedish som) in place of so.