You shall not take the name of YHWH your God in vain, for YHWH will not hold him guiltless who takes his name in vain.
Deuteronomy 5:11
This commandment isn't about saying the words God or Yahweh, etc. It's about dishonoring God's reputation by acting unjustly or sinfully in His name and by falsely attributing words or doctrines to him. In other words, anything that misrepresents God or besmirches his character is "taking YHWH's name in vain." Don't speak or command in God's name if God wouldn't approve of what you're saying. Don't use his name casually. Keep it close. Honor it. Use it sparingly and reverently.