I know it means caught “red-handed” but what is the origin of the term? Thanks.
For sure the “dead” meant “positively.”
The “to rights” part is a bit more unclear. While the whole expression dead to rights almost certainly is a US expression appearing in 1859, the “to rights” part is British originally. It generally meant “at once.” This is probably what it meant. Absolutely, no questions asked, immedidately, at once, guilty of something..
Does the “rights” refer to rights, i.e., civil?
I doubt that they were talking about “rights” in a legal sense.
In looking again at the OED, under “rights,” it’s possible that the “rights” part might have meant “The true account or interpretation of a matter.” But that meaning was only used with “rights,” not usually with “to rights.”
I drew the “to rights=at once” conclusion from Christine Ammer, Am. Heritage dictionary of Idioms. She’s way smarter than I, so she’s probably correct.