You are asking about this statement of Jesus, from Matthew 10:34: "Do not think that I have come to bring peace on earth; I have not come to bring peace, but a sword."
You're not alone in feeling that this statement seems antithetical to the entire tone of Jesus' message and ministry. But, really, all four gospels record Jesus as going to great lengths to make it clear that his was not an easy path and that holding firmly to spiritual truth will generate an equally firm resistance from the fear-based collective consciousness that seeks to hold us back. The underlying metaphysical truth, I think, is simply that choices have consequences. The brighter the light, the darker the shadows. In choosing to see life differently —to embrace our true Oneness with God instead of accepting old beliefs of separation, guilt, shame and suffering—we will arouse the opposition, not only of others who believe differently, but of those old thoughts in our own consciousness that will strive to maintain their control over us.
The good news that Jesus Christ taught and demonstrated is so joyful, creative and loving that it might seem simply inevitable that everyone will want to embrace it. And the transformation within us as we open our hearts and minds to that good news is so dramatic that it might seem no resistance could even be possible. Jesus realizes that we need to be vigilant—not so that we can attack others, but so that we can defend our newfound spiritual empowerment against the shadows that feel threatened by it.
So the path to the kingdom of heaven—the path of Christ consciousness—will not always feel peaceful. But we can be certain that whatever strength we need to maintain our focus will be available as we need it.