The children of legendary comic-book artist Jack “King” Kirby took it on the chin yesterday in their bid to claim the copyrights to some of the world’s most famous costumed superheroes.

A judge ruled that Captain America, Iron Man and more than a dozen other superheroes belong exclusively to Marvel Entertainment, along with the millions in “earnings from blockbuster movies made and yet to be made.”

Manhattan federal Judge Colleen McMahon said Kirby, who died in 1994, helped create the characters as “work made for hire” at the direction of then-Marvel editor Stan Lee.

Under the law in effect at the time, that means Marvel is the “author” and holds the copyrights — “whether that is fair or not,” McMahon said.

Marc Toberoff, the lawyer for Kirby’s four children, said they planned to appeal.