Acts 5:29- Obey God or Man?

Acts 5:29 says, "Then Peter and the other apostles answered and said, We ought to obey God rather than men."

This is one of the trickiest verses to understand until you take it into context.  One cannot say they will only obey God who they cannot see if they cannot obey their human authorities. The Bible is clear that God in His wisdom has set human authorities to do His work.  For example, he set Moses to rule over the nation of Israel and then we have Joshua, the judges and eventually kings.  Romans 13 is clear that people are to submit and respect authority.  That this verse really means is this- that when an authority regardless of position whether parent or not, gives a command that is contrary to the Word of God then he/she has to be politely refused.  

An example of this would be Daniel and his friends.  First, Daniel knew he was not to eat of the king's food because it was against God's Law back then.  Second, there was the example of Daniel's three friends Shadrach, Meshach and Abednego although they respected the king refused to bow down to the idol and respectfully took whatever punishment the king threw on them.  Third, Daniel chose to continue praying to God even if it was against the law of Persia that time.  In short, they disobeyed not because they rebelled against human authority that God has ordained, rather it's because the human authorities told them to do something that was against God's orders.  Likewise, the verse in context can be seen that Peter and his fellow apostles were told to stop preaching about the Lord Jesus Christ by the Pharisees but they continued to do so because it was what God has commanded.