Amit Dave/Reuters

Narendra Modi is an early riser. He is awake before dawn and soon ready for the yoga and meditation routines that help prepare him mentally, physically, and spiritually for the day ahead. Before he settles into position to follow an exercise regime that has its roots in centuries of Indian tradition, however, he has a more contemporary reflex that will not wait. He connects to the Internet.

"It's a mechanical process now for me to reach out for my iPad within the first four to five minutes after I wake," India's prime minister told me in an interview. "Likewise every day before I go to bed I take a look at my emails and check any relevant news that I may not have heard about and want to read." His Internet habit started, he said, in the late 1990s, when he discovered it was the best way to keep in touch with what was happening in his home state of Gujarat. He has tried to keep up with the latest online applications ever since, so much so that it is often Modi who introduces his younger staff to new technology—he claims he was the first to use a digital camera during India's 1999 elections and encouraged his staff to use the WhatsApp messaging platform "before it had become popular."

Modi signed up for Facebook and Twitter in 2009, and from a slow start his number of "friends" and followers grew steadily. One of the skills he looked for in the young men he recruited for his 2014 general-election campaign was the ability to use social media to its best effect. One of those men recalled, "It was our very first meeting and he asked how he could double his Facebook likes." Modi's enthusiasm for online communication caught the attention of Arvind Gupta, the head of information technology for the Bharatiya Janata Party (BJP), the Hindu-nationalist party Modi now leads. Gupta had been trying to persuade the party leadership to start moving with the times. Having worked in both Silicon Valley in California and India's own IT capital, Bangalore, he joined the party staff full-time in early 2010 and said that the BJP was barely in the game when it came to online campaigning. Gupta told me that it seemed as if Modi was alone among the party's top names in understanding the potential of the online medium.

India's 2014 campaign was not just the most Internet-savvy in the country's history—that was inevitable with all the technological advances since the last one in 2009—but also among the most technologically advanced anywhere in the world. The BJP wasn't alone in recognizing the utility of an online presence. But one rival candidate, Rahul Gandhi of the Congress Party, told a communications expert who went on to work for Modi that the real India did not live in the online world. "He said you are all urban guys, you think it's all about urban India, but this is a poor country," the Modi campaign staffer told me.

While it is true that in parts of rural India there is still no electricity, never mind a usable Internet connection, an estimated 240 million-plus people were online by the middle of 2014, an increase of 28 percent over the previous year. So while Gandhi was right to say that not all Indians were ready to get political messages via social media, many were, and those who did could pass on what they had learned to friends, relatives, and neighbors by word of mouth.

Still, the country's uneven access meant, according to a member of Modi's team, that "there were three elections happening at the same time" within India's 543 constituencies. "There was a pre-modern election in about 200 seats which didn't require a social-media campaign at all. Then there was the modern election, which would include semi-urban towns. And finally we identified 155 constituencies that could be said to be involved in a digital election."

The purpose of the digital campaign was not merely to increase Modi's "likes" or Twitter followers, although he would eventually accumulate enough Facebook fans to put him second only to Barack Obama among political leaders on the site. Almost one in six of all Facebook users in India were following Modi by the end of the campaign. The real objective was to turn "likes" into votes.

The Democracy Report

"The challenge," in Modi's own words, "was there was no campaign before on this scale using social media and technology that had been managed anywhere in the world, and hence we had no comparative basis from which to learn." Every conceivable online platform was exploited, including Pinterest, Tumblr, and StumbleUpon. Banner ads went up in a multitude of languages, and users were encouraged to interact with the ads as much as possible. They could use their mouse and cursor to "rub off" whatever problems bugged them most, like corruption or underdevelopment, and discover who had the solution to their problems underneath. There is no need for me to reveal who that turned out to be.

Meanwhile, anybody who chose to could submit a "selfie" and see it form part of a huge mosaic of similar photos that added up to an image of Narendra Modi. #SelfieWithModi was the top trending hashtag on social media within two minutes of its launch—not just in India, but worldwide. On Holi, the annual Indian festival of colors, thousands of people spray each other with brightly colored paint. Modi sprayed his followers with Twitter messages asking them to "spread the colors of peace, prosperity and happiness all over."

In return he invited them to shower him with ideas. He first tried crowdsourcing material for major speeches ahead of a July 2013 address to college students, using his Facebook page to ask for suggestions and receiving over 2,500 replies. Thereafter, Modi said he wanted to make crowdsourcing a regular feature of his campaign. Shashi Shekhar, who assisted in that effort, took me through how the process worked. The campaign would invite comments online a week or so ahead of speeches; staffers would then analyze and summarize those comments for the candidate. "He would get to read it on the plane on the way to wherever he was going, and some of the ideas would then actually appear in his speeches," Shekhar said. Modi was particularly keen to pick up local issues and concerns that he and his staff might otherwise miss.

* * *

When Modi is alone with his iPad in the early morning or late at night, he checks to see what news sites are saying. From his early days in politics, Modi has been convinced that the media, and especially the English-speaking media, is out to undermine him at any and every opportunity. One man who knows him well said, "There's a history to this. If you look at Mr. Modi, especially after the 2002 riots [in the province of Gujarat, where Modi was then chief minister], he's been at the receiving end of the majority of the media. So he saw a big need to communicate directly with the people because the media was not going to be positive to him, it was going to be hostile to him." For Modi, social media is not just a passion, but a necessity.

At BJP headquarters, Arvind Gupta said that in previous elections, the party leadership had felt powerless. "Our responses were totally dependent on the mainstream media who could choose to show our message or not. Social media changed the whole scenario." By the clever use of the right tweet at the right time, the party found that it could take control of the agenda and all but force TV, radio, and the print media to follow along behind. In this respect at least, Shekhar said Modi was able to dominate the election in ways that no Western leader has yet been able to achieve. "Unlike in the West, where the television and the news cycle set the agenda to a large extent, in India at this election ... [Modi] was not reacting all the time. He was defining the debate and then the media would react."

By so dominating the Twittersphere, the Modi campaign was able to not only get a story into the headlines, but also help douse the fires when a potentially negative one was starting to gather force. A good example came when, in order to complete his nomination papers, Modi had no choice but to reveal that he was married as a teenager and still had a wife. The story started to go awry for the Modi camp when questions were raised about his attitude toward women more generally. "Can women of this country trust a man who deprives his wife of her right?" asked the Congress Party's general secretary, Digvijaya Singh.

Shekhar remembered the day clearly: "If there had been no social media this would have been a huge mainstream-media controversy. The kind of story the mainstream media would paint was, 'Here was a woman who was abandoned, so how can you talk about women's rights if you didn't show proper responsibility?' and so on. But the moment the news broke out you had people on social media reacting with counter-stories and facts and the issue fizzled out. It was marriage when he was a teenager, it was never consummated; all these things came out."

The 2014 race may have only been a semi-digital election, but the impact of what was said and done online extended well beyond those constituencies with the highest number of Internet users. Still, even a passionate social-media advocate like Shekhar agreed that "overall the impact was on the conversation and the narrative, not so much in the actual votes, because I don't think digital has penetrated yet to such an extent that it was affecting the outcomes at the polling-booth level. Maybe at the next election." Modi found a way to dominate the social-media world. But in the end he hasn't managed to tweet his way out of engaging with those inconvenient journalists.


This article has been adapted from Lance Price's book, The Modi Effect: Inside Narendra Modi's Campaign to Transform India.

We want to hear what you think about this article. Submit a letter to the editor or write to letters@theatlantic.com.