Beware of practicing your righteousness before other people in order to be seen by them, for then you will have no reward from your Father who is in heaven.
There are certain spiritual disciplines that have an observable external element to them. We are warned by Jesus to be careful that we don't concentrate on the part that people see and thus exclude ourselves from the right motivation before God for His reward.
Jesus begins with giving (Matthew 6:2). In Jesus' day some Pharisees were so pretentious in their giving that they made a show of the gift, blowing trumpets in the streets as they made their way to the temple for the contribution. Jesus wanted us instead to give discretely, solely for the Father to see and reward. How that fits in a culture where giving is "rewarded" with a tax break from a massive taxing agency of the federal government is still for me to sort out. It kinds of makes me reticent about charitable deduction as a motivation.
The principle also holds true in prayer (Matthew 6:5) where we are warned against both public displays in our prayer and showy language in our prayers to get the notice of people. Instead, Jesus encourages private prayer focused on the holiness of God for the will of God. This kind of makes me rethink what role public prayer has in worship and in civil life. When it exists how can it hold to Jesus' own clear teaching? Maybe it means I ought to be more thoughtful when considering prayer in the public square.
And finally in fasting (Matthew 6:16), Jesus warns against making a fast public knowledge, instead asking us to only do so for the Father's eyes. He sees in secret and will reward our hearts. Public displays of religious devotion should make us suspicious of our motives, according to Jesus.