In the now all-too-familiar search for a motive that follows mass shootings in America, few recent cases have provided as seemingly clear a narrative as that of Nasim Aghdam, the woman who sneaked into the headquarters of YouTube, in San Bruno, California, on Tuesday and opened fire with a handgun, wounding three employees before killing herself. Aghdam was a YouTube content creator by trade; she starred in her own kookily amateurish music videos, sketches, fitness how-tos, and rants, many promoting veganism and all filmed in the same eerie, oversaturated hue. But she held a grudge against the company, which she believed had jeopardized her work by unfairly censoring her videos and subjecting them to “demonitization”—making them ineligible for advertising revenue. In a video posted last year, Aghdam explained to her followers that the reason YouTube was “discriminating and censoring us” was that “people like me are not good for big business.” Writing on her personal Web site, she concluded, “There is no equal growth opportunity on YOUTUBE or any other video sharing site, your channel will grow if they want [it] to!!!!!” According to Aghdam’s brother Shahran, “She was always complaining that YouTube ruined her life.” Prior to the attack, he and his father had warned police that she might target the company.

Aghdam’s unhinged prose and wide-eyed glare can convey the sense that she made YouTube into an all-powerful enemy from scratch, like the schizophrenic who believes that the C.I.A. is after him. In fact, a certain amount of paranoia and resentment defines many creators’ relationship with the platform that pays them. This stems mainly from YouTube’s moderation techniques, which are opaque and ever-shifting, guided by algorithms that, at least in the popular imagination of YouTube users, can reduce someone’s income to nothing on a mathematical whim.

In January, YouTube raised the threshold for monetization to a thousand subscribers and four thousand “watch hours” per month; any channel with numbers below that would no longer be eligible to receive ad revenue. The change was the latest in a series of attempts by YouTube to improve the friendliness of the platform to advertisers by cutting down on malicious content. Last March, an investigation in the Times of London revealed that YouTube’s automated ad-placing system had gone awry; in one case, a promotional video by L’Oréal appeared after a sermon by the Baptist preacher Steven Anderson, whose church the Southern Poverty Law Center classifies as a hate group. Major advertisers boycotted.

The Adpocalypse, as the crisis came to be known, cost YouTubers dearly in advertising revenue and reputation. The company went all out to try to salvage its image, demonetizing videos left and right. But the zeal to clean up the platform often put it at odds with the community. For years, full-time YouTubers had revelled in the rawness and immediacy of their medium; now they found seemingly innocuous videos struck for no reason. In September, the YouTube celebrity Hank Green tweeted a notice that he had received on his channel informing him that two of his videos—one called “Vegetables that look like Penises,” the other a dispatch from the Zaatari refugee camp, in Jordan—had been demonetized. “YouTube swiftly reinstated monetization on the Zataari video when we called them on it,” Green wrote. “But this whole situation is very very worrying.”

In the wake of Tuesday’s shooting, the question of what role demonetization may have played swiftly became a topic of speculation among YouTubers. Some expressed a kind of sympathy for Aghdam, condemning the attack even as they recalled their own experiences in the depths of the Adpocalypse. “I get it—oh, I get it,” Matt Jarbo, who goes by the handle Mundane Matt, said on his live-streamed show. (A clip from the broadcast has already been viewed more than seventy-four thousand times.) “The frustration is there,” he went on. “There were many, many, many nights where I would just lay at night completely flabbergasted, frustrated, and angry, because YouTube wasn’t communicating.” Jarbo first attracted an audience during the Gamergate controversy, in 2014. His position back then resembled that of many right-leaning commentators on Twitter this week, who saw the shooting as a tragic result of overbearing censorship. (As Andrew Torba, the C.E.O. of the “free speech social network” Gab, wrote in a post on Wednesday, “Censorship kills.”) Far more common, though, were the unequivocal condemnations of Aghdam and expressions of support for the company from high-profile YouTubers. Green tweeted, “This has nothing to do with YouTube policy. It’s a sad and horrific story of a person who built anger and hate inside of herself until it seemed like a good idea to get a gun and use it.”

Looking at Aghdam’s videos, you get the impression that only a delusional person might have expected them to attract more than the tiny audience that seemed to give her such pain. And yet she was something of a celebrity in her native Iran, where she was known by the name Green Nasim. In one of her most popular videos, according to the Times, Aghdam “wears a revealing purple dress, showing cleavage, and begins to slowly strip off her clothes to reveal a pair of fake plastic breasts.” All told, her YouTube videos racked up nearly nine million views and thirty thousand subscribers. In the online attention economy, fame often has nothing to do with talent and, in fact, can be spurred by its conspicuous absence. One could imagine how sudden success could be even more disorienting than failure for someone like Aghdam.

Reading the story of Aghdam’s unlikely fame and horrifying end, I was reminded of Edgar Welch, the twenty-eight-year-old man who, in late 2016, drove from North Carolina to Washington, D.C., and fired an assault rifle in the Comet Ping Pong pizzeria. Welch had been inspired to act by the conspiracy theory known as Pizzagate, which propagated false rumors of a child sex ring operating out of the pizzeria, overseen by Democratic Party officials—rumors that circulated, in part, on YouTube. The spectacle of Welch’s attack and arrest fuelled further concerns over fake news and malicious content, which had already gripped commentators in the latter days of the Presidential election. This set the stage, in turn, for the intense reaction by advertisers to the Times of London report, which then spurred the crackdown that, it seems, Aghdam fixated on before she committed her crime. If Welch symbolized the dangers of an unfettered Internet, then Aghdam reminds us that the quest to control it is scarcely less fraught.