Here’s the Scripture on the matter:
Romans 13: NASB
1Every person is to be in subjection to the governing authorities. For there is no authority except from God, and those which exist are established by God.
2Therefore whoever resists authority has opposed the ordinance of God; and they who have opposed will receive condemnation upon themselves.
3For rulers are not a cause of fear for good behavior, but for evil. Do you want to have no fear of authority? Do what is good and you will have praise from the same;
4for it is a minister of God to you for good. But if you do what is evil, be afraid; for it does not bear the sword for nothing; for it is a minister of God, an avenger who brings wrath on the one who practices evil.
5Therefore it is necessary to be in subjection, not only because of wrath, but also for conscience’ sake.
6For because of this you also pay taxes, for
rulers are servants of God, devoting themselves to this very thing.
7Render to all what is due them: tax to whom tax
is due; custom to whom custom; fear to whom fear; honor to whom honor. (NASB)
Some would argue we are to obey government and its laws even if they are in opposition to God’s laws and His Righteousness. The following verses in Romans 13 refutes this specious claim:
8Owe nothing to anyone except to love one another; for he who loves his neighbor has fulfilled
the law.
9For this, “YOU SHALL NOT COMMIT ADULTERY, YOU SHALL NOT MURDER, YOU SHALL NOT STEAL, YOU SHALL NOT COVET,” and if there is any other commandment, it is summed up in this saying, “YOU SHALL LOVE YOUR NEIGHBOR AS YOURSELF.”
10Love does no wrong to a neighbor; therefore love is the fulfillment of
the law.
11Do this, knowing the time, that it is already the hour for you to awaken from sleep; for now salvation is nearer to us than when we believed.
12The night is almost gone, and the day is near. Therefore let us lay aside the deeds of darkness and put on the armor of light.
13Let us behave properly as in the day, not in carousing and drunkenness, not in sexual promiscuity and sensuality, not in strife and jealousy.
14But put on the Lord Jesus Christ, and make no provision for the flesh in regard to
its lusts. (NASB)
So we see Paul teach to obey government and her laws yet in the following verses see God’s laws mentioned and how we are to keep them, above all love our neighbors as ourselves.
We already know the men and woman of faith throughout Scriptures resisted government and local authorities when wicked laws were enacted. Shadrach, Meshach and Abednego disobeyed a clear idolatrous directive:
Daniel 3: NASB
8For this reason at that time certain Chaldeans came forward and brought charges against the Jews.
9They responded and said to Nebuchadnezzar the king: “O king, live forever!
10“You, O king, have made a decree that every man who hears the sound of the horn, flute, lyre, trigon, psaltery, and bagpipe and all kinds of music, is to fall down and worship the golden image.
11“But whoever does not fall down and worship shall be cast into the midst of a furnace of blazing fire.
12“There are certain Jews whom you have appointed over the administration of the province of Babylon,
namely Shadrach, Meshach and Abed-nego. These men, O king, have disregarded you; they do not serve your gods or worship the golden image which you have set up.”
13Then Nebuchadnezzar in rage and anger gave orders to bring Shadrach, Meshach and Abed-nego; then these men were brought before the king.
14Nebuchadnezzar responded and said to them, “Is it true, Shadrach, Meshach and Abed-nego, that you do not serve my gods or worship the golden image that I have set up?
15“Now if you are ready, at the moment you hear the sound of the horn, flute, lyre, trigon, psaltery and bagpipe and all kinds of music, to fall down and worship the image that I have made,
very well. But if you do not worship, you will immediately be cast into the midst of a furnace of blazing fire; and what god is there who can deliver you out of my hands?”
16Shadrach, Meshach and Abed-nego replied to the king, “O Nebuchadnezzar, we do not need to give you an answer concerning this matter.
17“If it be
so, our God whom we serve is able to deliver us from the furnace of blazing fire; and He will deliver us out of your hand, O king.
18“But
even if
He does not, let it be known to you, O king, that we are not going to serve your gods or worship the golden image that you have set up.” (NASB)
And Peter and John after being ordered by the religious authorities to not preach Christ tell them that is it right to heed them or God:
Acts 4: NASB
13Now as they observed the confidence of Peter and John and understood that they were uneducated and untrained men, they were amazed, and
began to recognize them as having been with Jesus.
14And seeing the man who had been healed standing with them, they had nothing to say in reply.
15But when they had ordered them to leave the Council, they
began to confer with one another,
16saying, “What shall we do with these men? For the fact that a noteworthy miracle has taken place through them is apparent to all who live in Jerusalem, and we cannot deny it.
17“But so that it will not spread any further among the people, let us warn them to speak no longer to any man in this name.”
18And when they had summoned them, they commanded them not to speak or teach at all in the name of Jesus.
19But Peter and John answered and said to them, “Whether it is right in the sight of God to give heed to you rather than to God, you be the judge;
20for we cannot stop speaking about what we have seen and heard.” (NASB)
There are more examples I’m sure other posters will bring up. However, it is abundantly clear that when God’s Law is in tension with the wicked laws of mankind we are not to obey wickedness.