SHIBUSHI, Japan — The suspects in a vote-buying case in this small town in western Japan were subjected to repeated interrogations and, in several instances, months of pretrial detention. The police ordered one woman to shout her confession out a window and forced one man to stomp on the names of his loved ones.

In all, 13 men and women, ranging in age from their early 50s to mid-70s, were arrested and indicted. Six buckled and confessed to an elaborate scheme of buying votes with liquor, cash and catered parties. One man died during the trial — from the stress, the others said — and another tried to kill himself.

But all were acquitted this year in a local district court, which found that their confessions had been entirely fabricated. The presiding judge said the defendants had “made confessions in despair while going through marathon questioning.”

The Japanese authorities have long relied on confessions to take suspects to court, instead of building cases based on solid evidence. Human rights groups have criticized the practice for leading to abuses of due process and convictions of innocent people.