The comedic aspect in A Midsummer Night's dream is expressed in the use of the potion that Oberon has Puck spread on the unsuspecting sleeping victims' eyes. It is funny when Titania wakes up and immediately falls in love with Bottom, whose head is turned into that of a donkey.
"Bottom makes several more references to being an ass, even going so far as to note that his face has become very hairy, but because he is a fool, he never realizes that he is, indeed, an ass."
The comedy is also evident in the potion's effect on Lysander and Demetrius who both end up in love with Helena. This is a result of mistaken identity. Puck is sent by Oberon to assist Helena with her love for Demetrius. He ends of making a mess of the whole potion outcome, at one point, Hermia chases Helena in the forest.
Aspects of comedy in The Comedy of Errors:
The most important aspect of comedy presented in The Comedy of Errors is the theme of mistaken identity. Shakespeare applies this theme through two sets of twin brothers in the play: Antipholus of Ephesus / Antipholus of Syracuse and Dromio of Ephesus / Dromio of Syracuse. The comic effect is produced when a character of the Ephesus set confronts a character of the Syracuse set. It should be noted in this regard that Shakespeare uses the same technique in some of his later comedies (for example, in Twelfth Night).
If you are writing a paper on an element of comparing and contrasting these two plays, you might find it helpful to visit our "How to Write a Compare-and-Contrast" essay.