Often called the poet of double vision, Shakespeare, the father of twins himself, wrote several plays involving mistaken identities and the ensuing confusion. The plot of A Midsummer Night's Dream also touches on the fact that sometimes different characters are not so different, after all, and are doubles of each other in some ways.
While the obvious similarity between Demetrius and Lysander is that they have both fought over the same women--Hermia in the beginning and Helena later in the comedy--they are also alike in their romantic pursuits in the forest after Puck drops the love potion on them. Their behavior in the forest points again to Helena's observation of the first act:
Love looks not with the eyes, but with the mind,
And therefore is winged Cupid painted blind. (1.1.234)
While Lysander's mind is romantic, much like that of Romeo as he is willing to risk his life in running away with Hermia, Demetrius's is much more calculating. He argues that Hermia should be his because he has made a contract with Egeus, her father. Also, that Demetrius's interest in Hermia is less than romantic is evinced by his rejection of Helena for his arrangement with the Athenian nobleman Egeus. And it is only in his greed that Demetrius pursues Hermia when he learns that she has run away with Lysander. As they talk in Act I, Lysander's comment to Demetrius points to the fact that Demetrius has made a contract with Egeus that has less to do with love than with position:
You have her father's love, Demetrius:
Let me have Hermia's. Do you marry him. (1.1. 94-95)
Indeed, the main difference between Demetrius and Lysander is in their natures. Demetrius's love is cruel, while Lysander is, like Romeo, a true lover, willing to risk his life for his love. His love is romantic.
The most obvious similarity between the two in A Midsummer's Night Dream is that they are both fighting for the love of Hermia.
They are both also citizens of Athens who have some degree of wealth and travel in or near royal circles. (We know this partially because Shakespeare has them speak in Iambic Pentameter, versus the prose in which the laborers speak. Also, they have access to the Duke both in the beginning when Hermia's father is pleading for him to intervene in Hermia's love life, and at the end when they join the Duke at the wedding feast.)
They are different, in that Lysander seems to be after Hermia for true love, whereas Demetrius wants her for power and status. Lysander risks hatred from the father and reproach from the Duke to love Hermia. He also faces danger and ridicule for disobeying the Duke's orders and running away with Hermia into the woods.
Demetrius, however, wooed Hermia with gifts while she was involved with Lysander, and he cozied up to Egeus so he would have an ally on the inside. Also, when Demetrius finds out that Hermia and Lysander have fled, he takes after them rather than letting her go be with the one she loves (which denotes a selfish rather than a selfless affection.)