A murder mystery plot twist I've never seen (possibly open spoilers)

No names are springing to mind, but in my reading of vintage mysteries I’ve stumbled across that solution a few times. When Christie’s book came out, many people hated hated hated the twist because they thought she cheated. That’s probably a major reason why few deliberately copied her.

Other writers have twisted the idea in interesting ways. Percevil Wilde wrote several books in which five narrators give their accounts of what happened in the murder, the twist being that one of them is the murderer and cleverly talks around their involvement without ever actually lying. Kenneth Fearing, who wrote The Big Clock, also wrote all his mysteries that way, with even more narrators.

You just brought to mind the movie Beyond A Reasonable Doubt, where the idea is that a guy and his boss set out to show that the courts shouldn’t be convicting someone for murder on purely circumstantial evidence. And so the guy frames himself (with purely circumstantial evidence that doesn’t really prove anything but looks pretty bad) for a recent murder, and gets found guilty — and then, right as his boss is going to clear his name by producing the proof about this circumstantial evidence, said boss and said proof go up in flames. So he now does all he can to prove he isn’t the murderer, with the advantage of already knowing how to truthfully explain away each piece of purely circumstantial evidence he manufactured — and with the advantage of knowing all about the real crime, which, as it happens, he committed.

And in a very similar fashion (in fact the scene in which the big baddy hears a fellow cop’s theory about what is going on is basically ripped off in your film and then kills said fellow cop), LA Confidential

So an inside-out version of the OJ Simpson crimes.

First the cops unsuccessfully frame an actually guilty OJ. Then OJ writes a disturbingly accurate tell-all book about how somebody other than him would have done it. In his opinion at least.

Sometimes the real world is as wacky as the best of fiction.

No, that’s the book I was thinking of. I guess ‘side kick’ was too strong a title for the interaction between them, but it certainly seemed way more friendly than your usual detective/potential suspect.

Zaphod Beeblebrox cauterized his own brain so he wouldn’t remember why he wanted to go to Magrathea. But he also left his initials there so his future self could figure out who had done it.

No murder, but there is a mystery, in Now You See It.

See also Witness (1985) - although that gets revealed about halfway though the film.
And Off Limits (1987) - every mid-80s action movie cliche smashed together into a buddy cops in Vietnam flick

There was also the variation of the judge who is trying the murder case turning out to be the killer who also framed the defendent Suspect (1987)

Man, the mid-80s really leaned into the “person-you’d-least-expect-is-the-guilty-one” trope a lot.

There was also the inverse of the OPs scenario, where the detective investigating the murder ends up being arrested for it because everything thinks he did it and was botching the investigation on purpose, although he was innocent - Presumed Innocent

Not a murder mystery, but…

Angel Heart, tho more horror/fantasy. {ok spoiling the title since that’s the custom in this thread}

A closer COLUMBO match might be A FRIEND IN DEED, where the police commissioner who tells Columbo which sort of suspects to zero in on — by explaining how the evidence sure seems to him to point to an experienced burglar who got interrupted and then opted to silence a potential witness — decides, hey, as soon as Columbo can plausibly get a warrant for me and mine to search the residence of this or that suspect, that’s where I’ll plant some evidence before showing up with the investigators I’ll personally order around: as the guy who can say stuff like Oh Make Sure To Check Under The Sink After You Look Behind The Stove.

I was responding to Gyrate’s question about whether there was a story in which the dog did it. But I agree that your choice is a better fit for the OP.

Baroness Orczy’s The Old Man in the Corner. Orczy created a detective story archetype of the armchair detective . The book is a series of short stories, where the final one The old man – who never gave a name, turns out to be the killer and disappears.

Ellery Queen’s anthology 101 Years’ Entertainment has a story that fits the criteria perfectly.

They ALL did it! But if you wanna know who killed Mr. Boddy, I did: in the hall, with the revolver. Okay, Chief, take 'em away; I’m gonna go home and sleep with my wife!

Two more from 101 Years’ Entertainment:

“The Eleventh Juror” by Vincent Starrett, where the aforementioned juror turns out to be the killer.

“The Hands of Mr. Ottermole” by Thomas Burke is close: the killer is a cop investigating stranglings. It was made into an episode of Alfred Hitchcock Presents.

In movies, there’s the Joe E. Brown drama Painted Faces, which is clearly influenced by “The Eleventh Juror.”

One episode of Murder, She Wrote comes to mind: Season 3, episode 3, “Unfinished Business”.

That’s the outcome of a 2022 historical mystery movie set a couple decades before the civil war The Pale Blue Eye

However, while the identity of the murderer is a surprise to both viewers and a very famous historical figure who is assisting in solving the case, the murderer knows that they did it unlike a few suggestions in this thread.

That was the first thing I thought of.

There’s Newbery-winning YA mystery, which if you ask me, is entertaining enough for adults to enjoy, called The Westing Game, in which there is an apparent murder. The heirs to the murdered man’s considerable fortune are asked to investigate it, ostensibly because the police don’t realize it’s a murder.

The murdered man isn’t really dead-- he’s assumed a new identity, and is among the investigating heirs. The real game is to figure out which one-- and first of all, to figure out what the real game is. Nobody does, so he fakes the death of that identity as well; there is then another identity to be uncovered. Only one heir realizes at that point what the real game is, and, realizing that, what the next identity must be, walks into his office, and wins.

Seriously underrated film, that one.