Freedom of speech is not granted absolute protection. People have a right to speak their thoughts, a right to Tweet freely, and a right to think in whichever way they want. However, just as a person can be shunned by their friends after making an extremely insensitive comment, an internet user can be shunned for Tweeting a certain message. Freedom of speech guarantees you a right to speak, not a right to avoid the repercussions. It is necessary to call people out when they are racist or sexist so that we have less hateful speech and people think more about whether their comments are hurtful.
Cancel culture has worked before. When comedian Jess Hilarious had a fearful reaction to four Sikhs on her flight, she was called out for being racist, xenophobic, and ignorant. Before the canceling happened en masse, her response to the backlash was to brush the event off, telling everyone that she was entitled to her own opinions. After the canceling amounted to a substantial effect on her online fanbase, she came out with a public apology where she admitted to being ignorant and promised to educate herself further in the future. She also committed to donating $15,000 to the families of the victims of the Christchurch mosque shootings.
Critics of cancel culture might argue that this didn't actually change Jess and that she is now simply a racist who hides it because she is afraid of the backlash. It is, of course, desirable to fundamentally change people's racist beliefs, but this takes a lot of time and effort. Even if people stay silent out of fear, a decrease of hurtful language that makes the internet such a hostile environment for the oppressed, is still a very good thing.