TWO YEARS AGO, American hikers Shane Bauer and Josh Fattal, both 29, were arrested by Iranian officials along the Iraqi border. They have been jailed ever since in Iran’s notorious Evin Prison. Bauer’s fiancee, Sarah Shourd, who had accompanied them and was also arrested, was released on bail more than a year later. According to lawyers for the still-detained men, a verdict in their trial could come within a week. It is time for Iran to let them go.

The expected court decision comes after two years in which Mr. Bauer and Mr. Fattal were denied due process or a fair hearing on espionage charges. Much of that time they were not charged with any crime and had no access to counsel. Masoud Shafiei, who is now the Americans’ lead attorney, has said he hopes their release is imminent and could coincide with the start of the Muslim holy month of Ramadan, a time when many pardons are typically issued.

Promises of leniency by Iranian President Mahmoud Ahmadinejad in the case have not been borne out. Ms. Shourd languished in solitary confinement for some 14 months before her release. For all three, charges should have been brought within four months, according to Iranian law, and they should have had the right to direct and private contact with an attorney. They did not.

In two court hearings since the hikers’ arrests, Iranian prosecutors have presented no evidence that Mr. Bauer, a freelance journalist and photographer, and Mr. Fattal, an environmentalist, have ever had involvement in espionage or intelligence activities. That’s because they haven’t.

We hope the Iranian government will demonstrate compassion for these innocent Americans who crossed the border unintentionally and who have suffered enormously as a result of their imprisonment. If the court finds them guilty on the charges of espionage, we hope they will be sentenced to time served and released.