DUBAI, May 30 (Reuters) - A Kuwaiti court sentenced three members of the country's ruling family to five years in jail on Monday for insulting the Gulf state's ruler and judiciary on an internet messaging service, a defendant in the case said, confirming local media reports.

The court handed out jail terms to three other men as well as to the three royals, the defendant, one of seven people acquitted in the case, told Reuters. The defendants convicted intend to appeal their sentences, he added.

The defendant declined to be named because the case is ongoing. Kuwaiti courts do not speak to the media and the government does not comment on ongoing court cases unless it is directly involved.

One of the convicted men is Sheikh Athbi al-Fahad al-Sabah, a former intelligence chief and brother of influential sports power broker Sheikh Ahmad al-Fahad al-Sabah, the defendant said. Sheikh Athbi is also a nephew of Kuwait's emir, Sheikh Sabah al-Ahmad al-Sabah.

Reuters was unable to reach Sheikh Athbi or his lawyer for comment on Monday.

All but one of the convicted men were found guilty of sending the insulting messages on a Whatsapp group. The court judged this a public space and its contents therefore punishable by law, the defendant said.

Kuwait has one of the most open political systems in the Gulf and elected lawmakers and media commentators often attack the government and senior ruling family members over policy.

But the emir has the final say in political matters and criticising him is forbidden. Dozens of Kuwaitis have been jailed for comments made in public and online that the courts deemed insulting.

It is not the first time that ruling family members have been prosecuted for sensitive remarks. Sheikh Ahmad al-Fahad was given a suspended prison sentence and a fine in December 2015 for quoting remarks by the emir without permission.

In 2012 police released a ruling family member after holding him for several days over remarks on Twitter in which he accused the authorities of corruption and called for political reforms.

(Reporting by Sylvia Westall; Editing by Gareth Jones) ((sylvia.westall@thomsonreuters.com; Dubai Newsroom +971 56 216 6204; Reuters Messaging: sylvia.westall.thomsonreuters.com@reuters.net))