“As well as” is used either to compare or to express “in addition to.” Simple, direct comparisons using “as well as” do not require commas, but commas are needed when “as well as” introduces a nonessential component while meaning “in addition to”; one comma only when at the beginning or end of a sentence.
As an aside, there's an interesting wrinkle that may be noted about “as well as.” Although frequently substituted for “and,” its ability to add is not as complete. With “and,” it would be correct to say, “John and Paul live in the house,” but since “as well as” cannot treat a compound subject as plural, one is only able to say, “John as well as Paul lives in the house.” This limitation will be highlighted in a more extended version of the following that is yet to come:
Alive and blessed with math-like skills,
“As well as” to “in addition” adds “to.”
In cases such, a comma it takes
If starting sentence or lesser unto.
Comparing directly, simply, in prose,
“As well as” a comma doth never require.
But extras offered, unneeded they be,
Must dress in commas as central attire…
Since parenthetical, clearly apart,
And nonessential to meaning like this:
“All gentlemen here, as well as there,
Should look to God for lasting bliss.”
As well as weighing sameness state,
“As well as” joins up parts in pairs.
A crown of commas shall it rate
In nonessential-clause affairs.