An appeals court has upheld a four-year prison term for a Czech national for carrying out two attacks on trains and blaming them on Islamic militants.

Prague's regional court ruled in January that 71-year-old Jaromir Balda cut down two trees in 2017 that fell on train tracks near the city of Mlada Boleslav, about 50 kilometers (30 miles) north of Prague. Two passenger trains later hit the trees. Nobody was injured.

The retiree also placed pamphlets at the sites with threats of extremist attacks planned on Czech territory.

Prosecutors said the man's motivation was to incite fear of Muslims and attacks.

Balda pleaded guilty but claimed he didn't want to harm anyone. The court also ordered him to undergo psychiatric treatment.

Tuesday's ruling by Prague's High Court is final.