Writing Mechanics: Punctuation   embedded lists vertical lists
introductory clauses quotations
Introductory clauses

Clauses and many phrases which precede the main clause should be followed by a comma, especially if the phrase or clause is more than 5 words:

While he was eating breakfast, the boy was dreaming of lunch.

A comma preceding the same phrase or clause placed at the end of the sentence is not required by may be used for the sake of clarity:

The boy was dreaming of lunch while he was eating breakfast.