The internet is (usually and unfortunately), only text. There are no facial cues, hand gestures, etc. I, like I imagine a lot of people, can't easily detect sarcasm in text unless it's extremely over the top. And even then .. sometimes I have to wonder.
Sarcasm has to be the least effective way to communicate anyone could choose to use. You’re begging to be misunderstood and quoted as an idiot by using sarcasm these days.
You're right for online conversations or around people you don't know. Within friends groups or people that know you well (long-time coworkers) it's an effective tool, at least in my experience.
The hard part is not getting taken out of context by someone that overhears your conversations, so you should still exercise caution.