Robin the Boy Wonder, Batman’s aide-de-camp, will be killed battling a brutal enemy in a comic book published Wednesday.

The shocking demise of the Dark Knight’s sidekick will first appear in issue No. 8 of the offshoot title “Batman Incorporated,” but the aftermath of his death will ripple throughout the DC Comics universe, the publisher confirmed exclusively to The Post.

“He saves the world. He does his job as Robin,” writer Grant Morrison said. “He dies an absolute hero.”

Robin — a k a Damian Wayne, the 10-year-old son of Bruce Wayne — is slain fighting a hulking assassin who happens to be, in true comic-book form, a “brother” cloned from his genetic material.

And — SPOILER ALERT ! — unlike all the times he has swooped in at the last minute, Batman arrives too late to save his protégé.

A number of heroes have filled the role of Robin over the decades, including the first and best known, Dick Grayson, introduced in 1940.

PHOTOS: ROBIN THROUGH THE YEARS

The latest Robin, however, was the brilliant and caustic Damian, the illegitimate son of billionaire Bruce Wayne and Talia, the beautiful daughter of one of his deadliest enemies, Ra’s al Ghul.

Morrison, one of the industry’s top talents, brings an adult perspective to the grim tale.

Robin’s death, he said, will illustrate how parents lose sight of their kids when they fight.

“It’s all about the family and the family going to hell,” said Morrison, who threw in elements of his own parents’ divorce. “The two adults in the story are both culpable. The kid’s the good guy.”

Morrison, who brought Damian to the forefront in 2006, said he had created a full arc for the character, who grew from a violent, fledgling assassin to a selfless leader.

“What we did was turn this little monster into a superhero,” he said. “He’s a little brat, but he’s a super-brat.”

Damian isn’t the first Robin to die, but he’s the first to die at the height of his popularity with fans.

In 1988, a few years after Grayson moved on, the next Robin — the disliked, surly Jason Todd — was slain by the Joker after an infamous phone poll let fans choose whether the teen should be killed off.

Todd was resurrected in 2005.

So who knows if Damian will stay dead, or if a new Boy (or perhaps Girl) Wonder will take his place.

Noted Morrison: “You can never say never in a comic book . . . Batman will ultimately always have a partner.”

Batman Incorporated No. 8 preview by New York Post