PHNOM PENH (Reuters) - Cambodia's King Norodom Sihamoni on Friday granted a royal pardon to a leader of the main opposition party, at the request of Prime Minister Hun Sen, holding out hope for compromise after a period of rising political tension.

Kem Sokha, a leader of the Cambodia National Rescue Party (CNRP), was sentenced to five months in jail in September after failing to appear in court in connection with a case against two of his party colleagues.

He has been holed up at the CNRP headquarters in the capital, Phnom Penh, to avoid arrest for months and was pardoned at Prime Minister Hun Sen's request, according to a decree signed by King Sihamoni and seen by Reuters.

Government spokesman Phay Siphan said the pardon was an act of political compromise.

"Kem Sokha has already gone through the legal process and it is time for the prime minister to show his virtue and softness," the spokesman told Reuters.

The pardon comes after rising tension between the two main political parties, with the opposition complaining of a crackdown by Hun Sen's ruling party in a bid to intimidate critics before a general election due in 2018.

Kem Sokha, 63, was not immediately available for comment.

(Reporting by Prak Chan Thul; Editing by Amy Sawitta Lefevre and Robert Birsel)