Safewords are a formal way for the bottom to stop BDSM play. They add to the kinky mystique and drama, like contracts or other forms of protocol. Safewords might be used when "Stop, you muthafucka!" isn't considered cool enough. The most commonly used safeword is "red."
However, it's worth noting that a safeword is only as safe as the integrity of the Top. A safeword isn't safe if the Top doesn't respond correctly to it.
A safeword is not a magic incantation. It's not a "Beam me up Scotty, this scene sucks."
Too often, bottoms are persuaded to engage in dangerous play because they get a safeword. And too often, the safeword is not honored. (Or the bottom can't use the safeword because the bottom is in subspace or gagged or whatnot.) How does this happen? A bottom can get into this predicament because he or she is expected to show "good faith" by trusting a Top. That's ass backwards. Trust is earned. Always. Anyone can call himself (or herself) a Top (or Master or Dom). That doesn't mean he or she actually has the bottom's best interests at heart.
I think safewords, though glamorous, are superfluous. They add a layer of danger, rather than safety, to BDSM interactions. A Top should know the bottom well enough to figure out when they have had too much. A Top should be able to read expression or sounds. Or a Top could even use ordinary, pedestrian communication.
If your Top is a person you really don't know well, and needs a glitzy form of "stop", you should reconsider playing with that person.