FROM the earliest days of the Internet, robotic programs, or bots, have been trying to pass themselves off as human. Chatbots greet users when they enter an online chat room, for example, or kick them out when they get obnoxious. More insidiously, spambots indiscriminately churn out e-mails advertising miracle stocks and unattended bank accounts in Nigeria. Bimbots deploy photos of gorgeous women to hawk work-from-home job ploys and illegal pharmaceuticals.

Now come socialbots. These automated charlatans are programmed to tweet and retweet. They have quirks, life histories and the gift of gab. Many of them have built-in databases of current events, so they can piece together phrases that seem relevant to their target audience. They have sleep-wake cycles so their fakery is more convincing, making them less prone to repetitive patterns that flag them as mere programs. Some have even been souped up by so-called persona management software, which makes them seem more real by adding matching Facebook, Reddit or Foursquare accounts, giving them an online footprint over time as they amass friends and like-minded followers.

Researchers say this new breed of bots is being designed not just with greater sophistication but also with grander goals: to sway elections, to influence the stock market, to attack governments, even to flirt with people and one another.

“Bots are getting smarter and easier to create, and people are more susceptible to being fooled by them because we’re more inundated with information,” said Filippo Menczer, a professor at Indiana University and one of the principal investigators for Truthy, a research program at Indiana University that tracks bots and Twitter trends.