Parshat Mishpatim starts off by saying (21:1), “And these are the ordinances that you shall place before them.” Midrash Rabbah commenting on this Pasuk quotes Sefer Mishlei, which states (29:4): “A king, through Mishpat, will uphold the land, but a man who demands bribes will destroy it.” The Midrash explains that the Pasuk is referring to the way God created the world, through the attribute of Din, justice. We know this because the name of God used during Creation was Elokim, which connotes Midat Hadin. After Creation, Hashem realized that the world cannot only exist with Midat Hadin, so He introduced the Midah of Rachamim, mercy, into the world. We see this in the second Perek of Bereshit, throughout which God is referred to as Hashem Elokim. There is thus a synthesis between the name Hashem, denoting Rachamim, together with Elokim, representing Din.
What lesson can we learn from this? According to Rav Shimshon Raphael Hirsch, this teaches us how to deal with the world. We need to use both Rachamim and Din when dealing with people, a message which Parshat Mishpatim expresses many times. One example of this combination is Chesed. Chesed is, by its very nature, the opposite of Din. After all, if God were to punish someone by making him poor, what right would one have to give the poor man charity? The Midah of Rachamim allows for Chesed, both between people and between God and man. We learn from the Pasuk of Vehalachta Bidrachav (Devarim 28:9) that we are supposed to try to copy God’s ways. If we imitate Hashem’s attribute of Chesed and learn to act with kindness to one another, we will merit the rebuilding of the Beit HaMikdash.