BANGKOK, Thailand — An Australian writer was sentenced Monday to three years in prison for insulting Thailand's royal family in his novel, a rare conviction of a foreigner amid a crackdown on people and Web sites deemed critical of the monarchy.

Bangkok's Criminal Court sentenced Harry Nicolaides to six years behind bars but reduced the term because he had entered a guilty plea, the judge said.

Nicolaides, a 41-year-old from Melbourne, was charged with insulting Thailand's King Bhumibol Adulyadej and the crown prince in his 2005 book "Verisimilitude."

Passages in the book "suggested that there was abuse of royal power," the presiding judge told the court.

"I would like to apologize. This can't be real. It feels like a bad dream," a tearful Nicolaides told reporters before the verdict was announced. He said he had "unqualified respect for the king of Thailand" and had not intended to insult him.

Thailand is a constitutional monarchy but has severe lese majeste laws, mandating a jail term of three to 15 years for "whoever defames, insults or threatens the king, the queen, the heir to the throne or the Regent."

Public discussion of the monarchy's role was once taboo in Thailand, but has become more common amid growing concern about the eventual successor to the 81-year-old king, the world's longest-serving monarch. Bhumibol has no major official role in politics but commands immense respect from most Thais and is credited as being the nation's unifying force in times of crisis.

Nicolaides was arrested Aug. 31 at Bangkok's international airport as he was about to board a flight home, apparently unaware of a March arrest warrant issued in connection with his novel, according to rights groups. He was indicted in November and denied bail.

Nicolaides lived in Thailand from 2003 to 2005 and taught in the northern Thai city of Chiang Rai. He has described his novel as a commentary on political and social life of contemporary Thailand.

'Unspeakable suffering'"Tell my family I am very concerned," he told reporters. He said he endured "unspeakable suffering" during his pretrial detention but did not elaborate.

Reporters Without Borders has called on authorities to drop the charges against the Australian, saying "his novel never intended to threaten or defame the royal family."

The severity of Thailand's lese majeste laws was highlighted last year when a Swiss man, apparently acting in a drunken frenzy, was found guilty and given a 10-year prison sentence for defacing images of the revered monarch. It was the first conviction of a foreigner for lese majeste in at least a decade. The man was pardoned by the king after serving about a month behind bars.

New Prime Minister Abhisit Vejjajiva said last week his government would try to ensure the law is not abused. But he said the monarchy must be protected because it has "immense benefits to the country as a stabilizing force."