Social media’s dark side has transcended the psyche of individuals and companies to taint our nation’s democratic institutions. When political ads appear on Facebook from sources called “American.made” or “Being Patriotic” but are actually from Russian “troll farms,” it’s something to take seriously in our sacred democracy. At the same time, we’re learning that social media can influence society more than we think. Historically, media have changed politics. This, however, is a game-changer.

The recently disclosed slew of ads that were bought by Russian troll farms on our biggest digital and social media networks reflected an attempt to influence voters, sow discontent and even inspire Americans to fight one another. The Russian efforts reached an estimated 126 million people on Facebook alone but they also targeted Twitter, Google’s YouTube and other networks. Typically, social media ads target users based on geography, demographics or lifestyle. These ads centered on immigration, race, religion and gun control.

It’s clear the Russian-bought ads strategically focused on controversial or divisive topics for a reason. Public release of just a sample of the 3,000 ads shows a sophisticated influence campaign on the 2016 presidential election via social media advertising content. We now can see some ways in which the nation’s democratic process was under attack. What is less clear is how we will mount an effective defense against future attacks. Only a concerted effort from the world’s biggest tech companies, the government and the American public will give us a fighting chance.

There needs to be a greater sense of corporate social responsibility and higher standards. In the age of digital news consumption, the tech giants that own these platforms are media companies for all intents and purposes and they share a large part of the responsibility for misinformation. Representatives from the companies have told lawmakers that they are conducting internal investigations, though they aren’t complete. The companies have also been removing advertisements and other content that Russian troll farms have created, though they rightly fear legitimate content could also be squelched.

Some of the most effective Russian content came in the form of Facebook groups and events that are not paid for and are open to anyone who uses Facebook. All media platforms, including newspapers, have struggled with whether and how to control user-generated content such as comments. Comments sections represent another form of social influence that may well have been compromised.

Software bots have also been a problem on these social networks, spreading misinformation and amplifying false narratives. The companies have been working to shut down malicious bots, but they must do more, including making sure the sources of ads are accurately labeled and clear to the networks’ users. Even if profits are lowered by the need to promptly hire more employees to address the issue, it is a corporate social responsibility of the digital or social media company.

Lawmakers, including Sen. Dianne Feinstein, whose home state of California includes the headquarters for these tech firms, have warned the companies that they must do more. Congress’ move to disclose the social media ads is a great step toward public awareness, though lawmakers should tread carefully before passing laws that stifle free speech and freedom of the press. Again, these companies are media companies. It would be a dangerous precedent to shut down content through legislation.

The public ultimately holds the key to combating political cyberattacks. More than two-thirds of Americans get at least some of their news through social media, according to the Pew Research Center. We now know there is indeed “fake news,” though it’s not necessarily about information that is in opposition to your politics. News and advertisements need to be consumed through a critical, thoughtful lens. Before hitting that share button, question the source of the material. Is it from a trustworthy, well-known organization? Are you sharing content or joining a questionable cause just because it fits your political ideology? Remember: Russian efforts hit both sides of the political aisle.

With midterm elections a year away, tech companies, lawmakers and the public all have a responsibility to fight back. All Americans, regardless of political persuasion, should want fair elections that are not intruded upon by a foreign power.

Robert Quigley is a senior lecturer and innovation director in the School of Journalism at The University of Texas at Austin. He is a former social media editor of the Austin American-Statesman. Angeline Close Scheinbaum is an associate professor in the Stan Richards School of Advertising & Public Relations at The University of Texas at Austin and editor of the scholarly book “The Dark Side of Social Media: A Consumer Psychology Perspective” (Routledge, 2018).