This is a matter of style. If you always use a comma, then it's probably easier for you to continue to do so for the sake of consistency.
But, for instance, The Chicago Manual of Style, 6.22, says this:
When independent clauses are joined by and, but, or, so, yet, or any other coordinating conjunction, a comma usually precedes the conjunction. If the clauses are very short and closely connected, the comma may be omitted (as in the last two examples) unless the clauses are part of a series. These recommendations apply equally to imperative sentences, in which the subject (you) is omitted but understood (as in the fifth and last examples).
We activated the alarm, but the intruder was already inside.
All watches display the time, and some of them do so accurately.
Do we want to foster creativity, or are we interested only in our intellectual property?
The bus never came, so we took a taxi.
Wait for me at the bottom of the hill on Buffalo Street, or walk up to Eddy Street and meet me next to the Yield sign.
Donald cooked, Sally poured the wine, and Maddie and Cammie offered hors d’oeuvres.
but
Electra played the guitar and Tambora sang.
Raise your right hand and repeat after me.
Not only does CMOS point to some situations where the comma may be omitted (and what qualifies as "very short and closely connected" is a matter of opinion), it also qualifies its statements about the use of commas with the words usually and recommendation.
In other words, there is no absolute rule. The use of a comma in the example sentence in the question is probably more common than not—but the lack of a comma isn't actually wrong, unless you are following a specific style guide or other form of prescriptive grammar that says to never omit it. But, in that case, it's only wrong according to that particular guidance.