Here are discussions of seven types of situations in which the presence or absence of a comma depends on various factors.
1. Word Function
Whether a comma follows a word sometimes depends on the function of the word. For example, when now is employed at the head of a sentence to refer to the present time, there’s no reason to separate it from the rest of the statement: “Now you know.”
But when now serves as an interjection to mark a transition or attract someone’s attention, it should be set off: “Now, have you had dinner?” (That same series of words could be used in a temporal sense, though: “Now have you had dinner?” suggests that the writer is impatient with the person the question is directed to.)
2. Before Because
A sentence such as “I didn’t want to go because I hadn’t enjoyed myself last time” implies that the writer is explaining that the lack of enjoyment isn’t a factor in reluctance to attend an event; the reason for the reluctance will presumably follow.
But if the meaning is opposite — if the lack of enjoyment is the reason for the reluctance to attend — a comma should precede because to signal that what follows the comma is a dependent clause: “I didn’t want to go, because I hadn’t enjoyed myself last time” Alternatively, the dependent clause can begin the sentence: “Because I hadn’t enjoyed myself last time, I didn’t want to go.”
An appositive is a word or phrase equivalent in meaning to an adjacent word or phrase, as in “She wrote to her brother, John”; “her brother” and “John” mean the same thing, so they are appositives, and the comma is necessary to set it off. However, if the woman has more than one brother, write “She wrote to her brother John.”
Similarly, in “I met the writer, Jane Doe,” the comma is correct only if the writer has been alluded to before without mention of her name. Otherwise, the comma between the appositives suggests that only one writer exists. (And that puts me out of a job.) Even if writer is modified, the meaning differs: “I met the mystery writer, Jane Doe” suggests a previous reference to two or more writers, only one of whom writes mysteries, whereas “I met the mystery writer Jane Doe” simply specifies the genre in which Jane Doe writes.
4. Relative Clauses
Commas may or may not be necessary, depending on whether each statement in an otherwise identical pair of sentences uses the word that or which: In “The house that Jack built is falling apart,” the phrase “that Jack built” is essential to the sentence, which specifies a particular house. In “The house, which Jack built, is falling apart,” the emphasis is on what is happening to the house, and the identity of the builder is a parenthetical, so the optional information should be bracketed by commas.
“The house which Jack built is falling apart,” without commas, is also correct; it is identical in meaning to “The house that Jack built is falling apart.” However, the convention in American English is to avoid using which in this sense to prevent confusion with the meaning of the sentence with the parenthetical phrase.
5. Short Introductory Phrases
Many people choose to omit a comma after introductory phrases of just a few words, as in “During the summer I like to travel.” However, such omission is arbitrary when such sentences are compared to those with longer introductory phrases — and wrong in the case of transitional tags like finally, furthermore, and unfortunately — and for the sake of consistency, a comma should follow any introductory word or phrase.
6. Short Independent Clauses
In brief sentences such as “I will sort and you can staple” that consist of two independent clauses (complete thoughts that could stand on their own as distinct sentences), writers often choose to omit the otherwise obligatory comma before the conjunction.
But just as in the case of short introductory phrases, there is the problem of where to draw the line. Does one establish a rule about how many words each clause must contain to dictate whether a comma is employed, or does one judge each sentence on its own? Let simplicity be your guide: Always include a comma.
7. Coordinate and Noncoordinate Adjectives
When two or more adjectives sequentially modify a noun, depending on their relationship, they may or may not be separated by commas. To test whether to insert or omit commas, replace them with and. For example, “She was wearing a bright, cheerful expression” can also be written “She was wearing a bright and cheerful expression.” (The adjectives can be reversed in either case, too.)
However, “She was wearing a dark green blouse” cannot be rendered “She was wearing a dark and green blouse,” because dark and green describe the blouse in combination, whereas bright and cheerful separately describe the expression. Also, in this case, the adjectives cannot be reversed: “She was wearing a green dark blouse” is illogical because dark modifies green, not blouse. Therefore, no comma should separate the two terms.