Legalism is difficult to understand because it is seldom defined. The main thing about legalism is that it involves switching the roles of rules and principles. In their proper roles, rules are expendable, principles are not.
At first this sounds backwards. A rule sounds like a rigid thing; something that cannot or should not ever change or be broken. A principle sounds like a nice little insight on a subject, something that may or may not be essential in the practical application of a rule to our lives. But this is exactly backwards. It is the principle that is of supreme importance and must not be violated. The rule is useful so far as it carries out the principle. In a situation where it does not, it must be suspended or discarded.
In one sense, this puts more responsibility on us. As long as the rule is the supreme thing, we can follow it blindly. If the principle comes first, we must first understand which of the things that God has said constitute principles and which are rules; then we must understand the principle itself; and finally, we must figure out if and when the rule is upholding the principle. This may be difficult at times, but we are commanded to love God with all our minds, and scripture will help us along the way.
The main principle behind all of God's commandments, according to scripture, is life. The commandments are given to us to protect and sustain our lives. We were never intended to blindly follow the letter of the law, without thinking about the reason each law was given—its intent or its goal. And not all laws are of equal value in achieving the ultimate goal. We are expected to make distinctions. Jesus said to the Pharisees, "you tithe mint and dill and cummin [an extreme adherence to the letter of the law], and have neglected the weightier provisions of the law: justice and mercy and faithfulness; but these you should have done without neglecting the others. You blind guides, who strain out a gnat and swallow a camel!"1 So some laws are weightier than others. (God often rebuked the Israelites, and Jesus the Pharisees, for carrying out the more visible and less important parts of the law while breaking the less visible, but more important parts.) The varying importance of commandments is one reason we are commanded to meditate on the law. If the blind obedience of a soldier were all that God required of us, we would not have to think; we could just "salute and execute."
So how do we distinguish the weightier matters? First of all, some of them are explicitly stated, such as justice, mercy, and faithfulness in the passage just quoted. Elsewhere, Jesus identified the greatest commandment as loving God, and the second greatest as loving your neighbor as yourself.2
Secondly, we must contemplate the law, and scripture in general, to distinguish the principles. Principles may or may not be laws themselves. Principles are different from mere laws in that they explain things, such as the reason for a law. As mentioned already, God's laws are to protect and sustain our lives. Love is the fulfillment of the law because love always makes the best choice for the well-being of God and others (that is, choices that protect and sustain life, and choices that fulfill the purposes of life).3 Love is both a command and a principle.
Examples of the Explanatory Nature of Principles
When the Pharisees asked Jesus if it was ever lawful to divorce, He didn't just answer by quoting a law. He answered with a principle, an explanation. He went back to the historical account of the creation of mankind. This is because the intent of the laws concerning marriage is rooted in our natures and God's purposes for making the sexes. He wanted us to understand the reasons behind the commandments so we would know the laws' relationships to each other and how to apply them.
Concerning ceremonial hand washing before eating bread, Jesus said to the Pharisees, "Hear and understand. It is not what enters the mouth that defiles the man, but what proceeds out of the mouth, this defiles the man." When Peter asked Him to explain, He said, "Are you still lacking in understanding also?" And then He went on to explain that evil originates in the choices we make in our hearts.4
Note, first of all, that Jesus wanted his disciples to understand principles. It was the Pharisees who blindly obeyed rules. The Pharisees had the "salute and execute" mentality. We've heard their modern-day counterparts say things like, "I believe the Bible means what it says!," preferring blind obedience to rules, over understanding the principles being taught.
Next, consider what Jesus is saying about sin. It consists in and grows out of the intent of the heart; and its cure is not something superficial, like washing hands. This is no trivial matter. This goes to the core reason for Jesus coming into the world. If God's condemnation of sinners was based on their not washing, or not being circumcised, or not offering sacrifices, or not observing special days, then He could have gone no further toward redeeming us than He did by giving us the law. But, if sin consists in the intent of the thoughts of the heart, God could hope to redeem some by sending His Son into the world to show us His love by dying for us. And influencing our hearts to change, turning us from our sins, He would restore us to a relationship with Him, and He could justly forgive our sins (without condoning sin by doing so).
New Testament Commandments Are Spiritual in Meaning
In light of the "spiritual" nature of the Christian life—that is, that our hearts are governed by the truth of God's love sent down in Jesus from God, who is Spirit—in light of this fact, the commandments of the new covenant must be understood to have spiritual meanings. That is to say, they must have something to do with what God has done to change our hearts, and not have to do with merely superficial activities.
For example, baptism, for the Christian, is not about washing dirt off of our bodies. We needed our hearts changed and washed clean, not our skin. And God is not capable of changing our hearts by immersing us in water. If it was possible to do that, He could have just flooded the whole world instead of sending His Son to suffer and die. Water is of no use to God in affecting our hearts. The water of baptism is for us and those around us to learn from; it is an outward visible expression of what God has done in our hearts.5
Communion is based on the same principle. By eating the communion bread, we don't literally consume Jesus' physical body and thereby acquire His eternal life. Rather, we are reminded, when we eat the bread, that Jesus sacrificed His body for us. And we understand that our trusting in His love for us, which He displayed in the crucifixion, is just as real and valuable in sustaining our lives spiritually as physical food is to our physical bodies.6
Old Testament Commandments Are Transformed
Some Old Testament commandments derived their value from the fact that they represented something that Jesus would do when He came. Though they were outwardly visible physical activities, they symbolized a spiritual meaning that Jesus would one day fulfill in the hearts of those who trust in Him.7
Circumcision, the outward symbol, is redefined for the Christian in terms of the less visible, but more important reality of the power of sin being cut away from our hearts.8
Sabbath observation for the Christian is redefined from the outward setting aside of one day a week as holy, and from resting from physical labor, to spiritual meanings regarding our changed hearts.
In the case of keeping one day a week holy, the meaning is changed to the inner transformation of the heart, causing us to live in holiness seven days a week.9
In the case of ceasing from physical labor one day a week, the meaning becomes ceasing from our own labors of trying to repair our relationship with God, and beginning to rest in God's love, which He showed us in His Son's death, and relying on this to make us righteous. Compared with the surpassing greatness of this inner change, the visible outward observation of the Sabbath is rendered worthless!10
Love God and Do What You Want
God's main challenge in bringing about mankind's obedience was turning our rebellious hearts toward Him, which He accomplishes in those who put their confidence in the finished work of His Son.11 Once we love God, we will obey Him easily because what He wants will be what we want.12 The statement, "Love God and do what you want."13 reminds us to keep the emphasis on life-sustaining love, rooted in God's truth, and not on heartless legalism.
I should take this opportunity to point out that there is a segment, albeit rather small, of Christian denominations that believe baptism is more than a symbol. They believe that a person's nature changes at the moment they are baptized, making them a child of God by transforming them metaphysically. This belief is called "baptismal regeneration." The word "regeneration" simply refers to the Biblical concept of being born again. For those who believe in baptismal regeneration, one becomes a Christian at the moment they are baptized, and not a moment before. They believe that one must have faith already, but that salvation does not occur until they are baptized.
I believe this disregards the very important teaching throughout the entire Bible that what Jesus came to do was to influence our hearts to change by choice—not a metaphysical change, but a change we make with our free will in response to God's love expressed through Jesus' death on the cross. Those who hold to the doctrine of baptismal regeneration tend to take a legalistic approach to scripture. They tend to prefer rules to principles and like to quote scriptures for their superficial value rather than trying to understand the meaning the scriptures teach.
The danger of the belief in baptismal regeneration is that it would distract someone from seeing God's real goal in sending His Son—to transform our hearts through the impact that His love would have on our minds. It can, and often does, result in rule-oriented Christians who focus on outward actions to the exclusion of the intent of the heart.
13This was apparently derived from a quote attributed to Saint Augustine, a.k.a., Augustine of Hippo, in a homily on 1 John 4:8, in which he said (in Latin), "Dilige et quod vis fac." Which translated is "Love and then what you will, do." (See Wikiquote article.)