When you join two clauses that could each stand on its own as a sentence, put a comma, together with one of the conjunctions and, but, for, nor, or, so, and yet, between them:
For a closer look, click on each image to enlarge it.
Note that a conjunction doesn’t always signal the start of a new clause; in such cases, it doesn’t need to be preceded by a comma. Do not put a comma in front of a conjunction that’s just introducing another part of the same clause:
Not . . . but sentences, in particular, tempt writers to put commas where they don’t belong:
Learn more about compound sentences, run-ons, and comma splices.