AUDIE CORNISH, HOST:
Think about your first stop when you want the answer to a question. It's probably an Internet search, and it's probably Google. That's what many voters are doing right now, and this is why presidential campaigns spend a lot of time and a lot of resources to make sure it's their website, not something else that pops up at the top of search results. Here's NPR's Scott Detrow.
SCOTT DETROW, BYLINE: In February 2011, Eric Sherred was feeling good. The Republican had just landed a new assignment working on Rick Santorum's presidential campaign as a digital strategist. Part of the job - search engine optimization - making sure the campaign's website turned up high in Google searches. So Sherred was pretty happy. That is, until he went home, turned on Comedy Central and saw Stephen Colbert tell people to Google Rick Santorum.
(SOUNDBITE OF TV SHOW, "THE COLBERT REPORT")
STEPHEN COLBERT: And if you're eating nachos, you might want to put them down.
COLBERT: OK, so here's his problem. When you Google Santorum, the first result you get is, quote...
DETROW: And we have to stop the clip right there. Just know it's gross - really. The segment aired the day Sherred found out he'd be working on the campaign.
ERIC SHERRED: I just - I went home. I watched it, and it was just one of those most defeating moments because you're, like, well...
DETROW: Now, this problem had been dogging Santorum for years at that point. It was the result of an online stunt by Dan Savage - sex columnist who was upset by Santorum's views on homosexuality. Nearly a decade earlier, Savage had enlisted a digital army to create an unpleasant association with Santorum's name.
SHERRED: This was, actually, pretty much our top priority.
DETROW: The hostile site was an extreme example of what every campaign has to deal with. There's a lot of negative material out there, and campaigns need to make sure their websites are popping up ahead of those other sites in people's search engines.
SHERRED: Because when you're interested in something, you know, the common thought is, well, I'm going to Google it. And with that, you want to be sure that you're at the top of the results page.
DETROW: So Sherred and his team got to work.
SHERRED: So one of the things that we made a big focus on was posting content that actually contained, you know, Senator Santorum - Rick Santorum's name every single day.
DETROW: Google's search algorithm is secret, but outside links always play a big role. Sherred says they'd reach out to friendly bloggers, asking for links. This sort of digital grunt work is par for the course for political campaigns. Because so many voters turn to Google and other search engines to learn about candidates, observers are paying more and more attention to search trends. Republican digital strategist Patrick Ruffini has been studying Google Trends data in the days before this year's primaries and caucuses.
PATRICK RUFFINI: Particularly that very last day, in the morning of, you usually see something interesting that later gets borne out in some way in the election results.
DETROW: Like in New Hampshire, where searches for John Kasich skyrocketed ahead of his surprise second-place finish. In fact, Ruffini says Republican candidates' final share of search totals have been eerily similar to the percentage of votes they ended up with.
RUFFINI: It matched up to within a point or two in South Carolina, and it was almost as close in New Hampshire.
DETROW: That's not to say we should throw out exit polls Bernie Sanders has consistently outpaced Hillary Clinton on search traffic, probably because she's been a national figure for decades. As for Eric Sherred and the Santorum campaign, they kept plugging away, post after post, link after link. And then one day a few weeks before the 2012 Iowa caucuses, it happened.
SHERRED: We were very, very proud that one day when we finally, you know, clicked around and said, we're number one. We finally did it. So it's - that was a big day for us.
DETROW: All that hard work had paid off, so much so that four years later, when he ran a second time, Rick Santorum had no problem asking voters to go ahead and Google him. Scott Detrow, NPR News.