Over the past several weeks, Monalisa Perez of Halstad, Minn., and her boyfriend, Pedro Ruiz III, began their quest for YouTube fame by creating and posting videos of mostly harmless pranks: Mr. Ruiz climbing onto a tenuous tree branch and falling a short distance, or Ms. Perez feeding him a doughnut covered in baby powder rather than powdered sugar.

On Monday evening, the couple suddenly upped the ante when, the authorities say, Ms. Perez, 19, shot at a thick book that Mr. Ruiz, 22, was holding, apparently believing that the bullet would not make it through the volume.

But the high-risk stunt went horribly wrong: The bullet entered Mr. Ruiz’s chest and he died at the scene.

“I really have no idea what they were thinking,” Sheriff Jeremy Thornton of Norman County said in a telephone interview late Wednesday. “I just don’t understand the younger generation on trying to get their 15 minutes of fame.”

It was a preventable death, the sheriff said, apparently fostered by a culture in which money and some degree of stardom can be obtained by those who attract a loyal internet following with their antics.

In the couple’s last video, posted on Monday, Ms. Perez and her boyfriend considered what it would be like to be one of those stars — “when we have 300,000 subscribers.”

“The bigger we get, I’ll be throwing parties,” Mr. Ruiz said. “Why not?”

Instead, just hours after she posted that video, Ms. Perez was arrested and booked into Northwest Regional Corrections Center on suspicion of reckless discharge of a firearm, the sheriff said. Then, on Wednesday morning, prosecutors charged her with second-degree manslaughter. The charge carries a maximum sentence of 10 years in prison, a fine of up to $20,000, or both.

Ms. Perez, who is pregnant with her second child, appeared in court on Wednesday afternoon for a hearing and was released in the evening after $7,000 bail was posted.

The department has video recordings of the shooting, the sheriff said, adding that he would not release them.

In an interview with The Star Tribune of Minneapolis, Lisa Primeau, an aunt of Mr. Ruiz’s, said, “We called him our little daredevil.” Her nephew put “a dangerous twist on everything he did,” she added, once even “jumping into the swimming pool from the top of the house.”

Ms. Perez told investigators that she had shot Mr. Ruiz from about a foot away while he held a 1.5-inch thick book to his chest, the authorities said. She described using a firearm that matched the pistol that was found at the scene.

Mr. Ruiz had been “trying to get her” to fire the gun “for a while,” Ms. Perez told investigators, according to court documents. They state that he had set up one camera on the back of a vehicle and another on a ladder to capture the stunt.

To help persuade her to pull the trigger, Mr. Ruiz had even shown Ms. Perez a book that he had previously shot himself, she told investigators. In that case, she said, the bullet had not gone all the way through the text.

The gun, a gold Desert Eagle .50-caliber pistol, was a “very strong weapon,” the sheriff said, adding that “as far as I know,” it was legal for Mr. Ruiz to own it.

Claudia Ruiz, another aunt of Mr. Ruiz, told WDAY-TV in Fargo that before the fatal shooting, her nephew rationalized the stunt as a way to get more viewers and “get famous.”

Ms. Perez appears to have posted 18 videos on her YouTube channel since May 9.

In the videos, the pair’s stunts are interwoven with raw moments that chronicle their evolving relationship. Ms. Perez complains that living in a rural farm community in northwestern Minnesota turns a trip to the grocery store into an afternoon-long ordeal. Other scenes show Ms. Perez, Mr. Ruiz and their daughter eating baked pasta leftovers for lunch; the couple discussing how a relative’s offhand comment stung; and the pair falling into bed together, exhausted.

In one particularly poignant video, Ms. Perez takes viewers with her to the doctor’s office on the day she and Mr. Ruiz discover the gender of their second child. She tells viewers early in the video that she is secretly rooting for a boy.

“Fingers crossed,” she says.

Then, minutes later, with the camera pointed at the sonogram, she practically squeals, “Oh, it’s a boy!”

“That’s awesome,” Mr. Ruiz says. “That’s my boy.”

As of Wednesday afternoon, all but one of the videos had between 200 and 3,000 views.

But by the evening, many of them had several thousand. And the couple’s final video, which was linked to by news reports about the shooting, had more than 83,000 — and climbing.

This article was published first on NYTimes.com