Here's why:
* Independent clauses are complete sentences that can stand alone.
* "But" is a coordinating conjunction, meaning it joins two equal parts of a sentence.
* Commas are used to separate independent clauses when they are joined by a coordinating conjunction.
Example:
* I went to the store, but I forgot my wallet.
In this example, "I went to the store" and "I forgot my wallet" are both independent clauses. They are joined by the coordinating conjunction "but", so a comma is needed before "but".