At some point in the last five years, social media went from novelty to necessity -- for businesses, brands and pretty much anyone who wants to communicate a message these days. The problem? Not everyone has the time to build and cultivate their social media presence, let alone maintain it. And executives are busy enough without having to worry about sending out the company's tweets.

It should come as no surprise, then, that more and more companies are outsourcing their social media activities to marketing agencies that specialize in such things. In fact, according to the most recent “State of the Social Media Marketing Industry” report, 32 percent of marketers are currently entrusting their social media accounts to third-party businesses, up from 14 percent in 2010.

That means things are bound to go wrong -- and disputes between companies and the social media marketing agencies they hire are all but certain to arise. But in such a fledgling field, the laws haven’t necessarily caught up with technology. For instance, policy agreements on Facebook (NASDAQ: FB) and Twitter are notoriously vague, and the question of whether or not social media accounts can be considered “property” in the legal sense is still being debated. Such ambiguity, legal experts say, puts companies in a legal gray area when they find themselves in a dispute with a social media agency.

“Nobody thinks about it until it’s too late,” said Mary Gately, a partner in the law firm DLA Piper in Washington, D.C.

In a phone interview, Gately cited a recent case involving one of her clients, a small nonprofit organization, which found itself in a legal quarrel with the agency it hired to manage its Facebook and Twitter pages. Following what Gately described as a “cash-flow problem,” the organization fell behind on a payment to the agency. Without warning, Gately said, the agency changed the passwords on her client’s social media accounts, leaving them with no way to access them. It was an ultimatum: Pay up or no more tweets.

“They were helpless,” she said. “Before they knew what happened, they were locked out. The past-due amount wasn’t even 30 days old.”

Social media has become so engrained in our daily lives that we scarcely realize how dependent upon it we’ve become. But, like air, it’s something you notice quickly once it’s cut off. Moreover, an agency tasked with managing social media serves as the public voice of a company -- that’s a lot of power to hand over to a third-party agency.

Granted, many online marketing agencies have established solid reputations, but the last few years have also seen a proliferation of younger firms with little experience or even know-how, which is precisely why Gately expects to see more disputes over who owns a company’s followers and fans. (She cited one case in which an employee who had helped build a company’s Twitter following claimed ownership of those followers after he left.) The bottom line, Gately said, is that companies need to establish solid contracts to protect themselves.

“It’s important to get everything in writing up front in the event that something goes wrong,” she said. “This is vital. Have everything spelled out.”

None of this is to suggest that current laws offer no protections for companies whose tweets get hijacked. Trademark law, for instance, would prohibit a third party from using company logos and names without permission, meaning an unauthorized tweet or Facebook post on behalf of a company could cross over into infringement.

For Gately’s nonprofit client, DLA Piper was able to successfully wrestle the client’s social media accounts away from the third-party agency by going directly to officials at Twitter and Facebook. But this was after being unable to access the accounts for several weeks. If that doesn’t sound like a long time, try going a week without updating your status and see how quickly you start to feel as if you’ve been rendered radio silent. “The liability is quite harsh,” Gately added. “We live in this social media world where so much is riding on your followers and Facebook fans, and if you don’t have access to that, that’s huge.”