Sometime after Arthur Conan Doyle had publicly announced that no more Sherlock Holmes tales would be forthcoming, a young August Derleth wrote to Doyle for permission to carry on using a pastiche; Doyle approved the idea, and Derleth began a series of tales, eventually to run over 40 years, about Solar Pons, often reckoned the best of the many Holmes pastiches.
Similarly, before Sherlock Holmes lapsed into the public domain, several novels pitted Arsène Lupin against "Herlock Sholmes". And actually continue to do so, in the French-speaking world at least.
Douglas Adams's book Dirk Gently's Holistic Detective Agency was based on a script he'd written for Doctor Who ("Shada") that had never been completed due to a studio workers' strike. The character of Dirk Gently was created to replace the Doctor in the book, and the character of Richard MacDuff created as a Companion figure. Dirk Gently proved such an engaging character that Adams wrote a sequel, The Long Dark Tea-Time of the Soul, and was working on a third book when he died. Dirk Gently's Holistic Detective Agency actually borrows from both the above mentioned Shada and another Doctor Who serial, City of Death, which Adams co-wrote. Compare the Big Bad's plan in both.
The character of Professor Chronotis is lifted straight from Shada, in which he is a Time Lord who uses his room as a TARDIS. The version in Dirk Gently uses the first name "Urban" (but usually the nickname 'Reg'), gains a fondness for magic tricks, and is never specifically acknowledged to be a Time Lord, but makes a few implications that he has been alive for hundreds of years and possibly used to have multiple faces...
Similarly, Life, the Universe and Everything was largely based on his proposed script for a Doctor Who story, "Doctor Who versus the Krikkitmen". The role of the Doctor was taken by Slartibartfast (and towards the end by Trillian), largely because none of the other shiftless main characters of the Guide universe fit the bill.
In Kim Newman's novel The Quorum, several of the characters are fans of Captain Ersatz comics characters Amazon Queen (Wonder Woman) and The Streak (The Flash), with shades of Superman), and one is a comics writer creating Crisis on Infinite Earths-style series about them for comics company "ZC". The novel also mentions Dr. Shade, a British comics character who resembles The Shadow, whose first appearance was in Newman's story "The Original Dr. Shade", which in the course of describing the character's fictional publishing history performs a Lampshade Hanging by mentioning that The Shadow's publishers once sued over the resemblance. Amazon Queen and The Streak also appear in "Coastal City", along with Green Masque (Black Canary), the Darkangel (Batman), Gecko-Man (Spider-Man), the Outcasts (X-Men), Teensy Teen (The Wasp) and Blubber Boy (sort-of Giant Man), Vindicator ( a cyborg version of The Punisher) and Nightgaunt (probably Spawn).
"The Other Side of Midnight" includes a vampire slayer by the name of Barbie Winters.
Michael Shea's novel Nift the Lean was written as a sequel to Jack Vance's first Cugel the Clever novel before Vance himself wrote an official sequel. Thus, Nift is a Captain Ersatz of Cugel. However, since Nift is paired with a Barbarian Hero named Barnar, there's another level of ersatzes, as Barnar and Nift are respectively based off of Fafhrd and the Gray Mouser.
Minister Faust's From the Notebooks of Dr. Brain features several of these: Omnipotent Man (Superman), Flying Squirrel (Batman), Iron Maiden (Wonder Woman/Thor) and Fly Brother (Spider-Man).
In a rather bizarre example, where Captain Ersatz meets Ascended Fanon or who-knows-what, an erotic romance novel called The Stranger by Portia da Costa features an expy of the Eighth Doctor. He has the same name as the actor who played Eight (Paul), and is almost exactly the same other than the name 1 and being described as taller and younger than I personally would describe him, including the amnesia. And the heroine's surname, as some who've watched Withnail & I may know, was the surname of another character Paul McGann played. Oddly enough, this all merits a sort of Continuity Nod in a Television Tie In Novel - the heroine is mentioned as someone the Doctor knew 2 not, mind you, mentioned as someone he knew. Fandom has speculated about which writer of the Television Tie In Novels is "Portia da Costa". So this means the Doctor has a published and semi-canonNarmfulDate With Rosie Palms 3 "Claudia realised that caressing himself was as much a comfort to the young man as it was an act of sex. He seemed reassured by his body's own responses. But that took nothing away from the eroticism of his performance.", among other things, out there.
Most of the superheroes in Perry Moore's young adult novel Hero are blatant parodies of DC characters, Warrior Woman being the most obvious. The Man in Black is Batman, The Spectrum is Green Lantern, King of the Sea is Aquaman, and Uberman and Justice are Superman.
Doctor Who again: In the Faction Paradox series the Time Lords become the Great Houses, who travel in Timeships (TARDISes) and are led by a War King who is clearly the Master. The Homeworld of the Great Houses was formerly defended by artificial beings called "casts" (Shaydes from the DWM comic strip), and an attempt to produce semi-sentient casts created homicidal maniacs called "babels" (N-Forms from the Eighth Doctor novels). The Doctor himself is only referred to as "the Evil Renegade".
The short story "Now or Thereabouts" features a Faction recruit called Ceol, who is Kelsey from the pilot of The Sarah Jane Adventures, complete with references to her pink tracksuit and a friend called Maria who went to America.
When Telos Publishing lost its rights to publish Doctor WhoExpanded Universe material with the new series, they started making their own series, "Time Hunter", about a gentleman time traveller named Honoré Lechasseur and his travelling companion Emily.
In What They Did To Princess Paragon by Robert Rodi, the eponymous Princess Paragon is very obviously Wonder Woman. Other characters created by Bang Comics include Acme-Man (Superman), the urban vigilante Moonman (Batman, complete with campy 60s TV series), and other members of the Freedom Front (Justice League of America). Bang's rivals Electric Comics, meanwhile, created the explorer-team The Quasar Quintet (Fantastic Four), the irradiated monster Sherman Tank (Incredible Hulk), and the superhero team The Offenders (The Avengers).
Before creating the Wold Newton Family, Philip José Farmer wrote a series of novels about John Cloamby, Lord Grandrith, who was raised by apes, and his half-brother Doc Caliban, a two-fisted adventurer. As well as serving as a Deconstruction of the pulps, these books advanced Farmer's early theories about the relationship between Tarzan and Doc Savage, without actually naming names.
Reading the Ciaphas Cain novel Cain's Last Stand, it becomes obvious that Varan the Undefeatable is this to Adolf Hitler, down to being described as looking exactly like him down to the moustasche and flashy uniforms, along with a similar personality. If it weren't for the mutations he has in the book, one would think Hitler himself paid visit to the Warhammer 40,000 universe.
And it's pretty much open knowledge that the entire Ciaphas Cain series is a 40k version of Flashman.
Although with the caveat that Cain is a much more likable character than Flashy himself.
In Mary Gaitskill's novel Two Girls, Fat and Thin, Dorothy, the "fat girl" of the title, is a devotee (and at one point, employee) of novelist "Anna Granite" and her philosophy of "Definitism."
Aslan from The Chronicles of Narnia series, is very clearly a Captain Ersatz of Jesus. He could be argued as an Expy until the third book, where Lewis makes Aslan's real world identity quite clear.
This is a repeating theme in Jonathan Lethem's Chronic City, which contains numerous Captains Ersatz of various culture references large and small. Interestingly, just as many and varied cultural touchstones are included as themselves, helping create a pervasive feeling of a pop cultural zeitgeist almost but not entirely our own. A few examples:
One major character was the ghostwriter for eccentric playboy physicist Emil Junrow's witty memoir I Can't Quite Believe You Said That, Dr. Junrow, who as described bears no small resemblance to Richard Feynman, eccentric playboy physicist and writer of the witty memoir "Surely You're Joking, Mr. Feynman!"
The Muppets are replaced in the pop culture of this world by "Gnuppets"
Russ Grinspoon, described as "the lamer half of [the] well-forgotten seventies smooth-rock duo Grinspoon and Hale" is likely meant as an Alternate UniverseArt Garfunkel.
The main character of the superhero satire Super Folks by Robert Mayer has powers more-or-less identical to Superman (who's specified as missing and presumed dead at the beginning of the book). His secret identity is named David Brinkley, and because he comes from the planet Cronk, he's vulnerable to Cronkite. The book also includes ersatzen of Plastic Man and Mr. Mxyzptlk, among loads of others.
In Austin Grossman's Soon I Will Be Invincible, CoreFire, Elphin, and Blackwolf are easily recognizable pastiches of Superman, Wonder Woman, and Batman, respectively. Other characters are also less-obviously drawn from other Marvel and DC characters. The central superhero group is sort of like a cross between the Avengers and the JLA, Doctor Impossible is a bit Lex Luthor plus superpowers (and sympathy), Damsel is a bit Donna Troy + Ms. Marvel with some Storm thrown in, Rainbow Triumph is obviously Robin, Mister Magic is mostly Doctor Strange, and so on.
The EuroTemps short story "If Looks Could Kill", by David Langford, stars the overweight detective Caligula Foxe (Nero Wolfe), along with his legman Charlie Goodman (Archie Goodwin), his chef Franz (Fritz), and his associates Paul Sanza (Saul Panzer) and Terry Carver (Orrie Cather). Also mentioned are Charlie's lady friend Lila (Lily Rowan), paranorm detective Sally Cole (Sally Colt), and journalist Ron Cohen (Lon Cohen). DPR official Mr Cream might be intended as Inspector Cramer.
The Clive Cussler novel Night Probe! includes a British agent, Brian Shaw, who is hinted - strongly hinted - to be James Bond.
Hal Bishop is Ed Straker. (Named after actor Ed Bishop.)
Alex Storm is Alec Freeman
Dr Ventham is Colonel Lake. (Named after actress Wanda Ventham)
Dr Kolvoski is Dr Jackson.
Lt Gabrielle is Lt Ellis. (Named after actress Gabrielle Drake)
Captain Drake is Captain Carlin.
The SILOET Movers are SHADO Mobiles.
SKYDIVER is KingFisher
Lunar Base is the Moonbase. It's also the Moonbase from Space: 1999.
The BLOCKER spacecraft are the Interceptors.
The Myloki are the Mysterons, and the unnamed aliens from UFO.
In the Doctor Who Missing Adventures novel Burning Heart by Dave Stone, the Habitat is Mega-City One and Adjudicator Craator is Judge Dredd. Virgin Publishing actually had the rights to publish Judge Dredd novels at the time, some of which were by Stone, and apparently he was already writing the book before they decided it wasn't going to be a crossover.
Seyton later makes a cameo in the Doctor Who Missing Adventures novel The Shadow of Weng-Chiang by David McIntee, which features more prominently a character based on The Shadow, except that instead of being a Mighty Whitey who learned Eastern mysticism, Mr Woo/Yan Cheh is actually Chinese. Hsien-Ko, the immortal daughter of Li H'sen Chang from "The Talons of Weng-Chiang", is somewhat reminiscent of Fu Manchu's daughter Fah Lo Suee, although that might just be because she's a Dragon Lady.
The writings of Michael Moorcock contain many examples, but most blatantly his more Steampunk/Dieselpunk flavoured works often feature Sir Seaton Begg and Count Zodiac, who are Captains Ersatz of Sexton Blake and his recurring enemy Zenith The Albino. This is partly a Homage on Moorcock's part, as he's made no secret of the fact that his original decision to make Elric an albino was out of fandom for Zenith.
Artur Balder's Curdy series is filled with characters a bit too much inspired in some others, the most egregious being one to The Joker.
Charles Stross's Laundry novel The Apocalypse Codex features cultured female superspy Penelope Hazard and her rough-diamond minion Johnny MacTavish, who are barely disguised versions of Modesty Blaise and her sidekick Willie Garvin as magicians. It's even lampshaded with Hazard's codename within the Laundry, which is BASHFUL INCENDIARY.
John Golden has Heroes of Mazaroth as the focus of the second novella. It is World of Warcraft in all but name with a tremendous amount of in-jokes regarding the game.
Titus Crow is a intelligent, caring investigator who acquires a time machine clock about the size of a coffin, regenerates into a new body after crashing, and fights evil gods and aliens. Doctor Who had come out a decade earlier.