Remember that there are many ways you can express agreement or disagreement. There are special words/expressions that clearly indicate the intention and their appropriateness to the situation. These words/expressions can be formal or informal but the situation dictates their specific functions.
Examples:
Of course, I agree
No, seriously, I believe otherwise