Thailand's latest political crisis traces its roots back to January when Prime Minister Thaksin Shinawatra sold his family's stake in the telecoms firm Shin Corp.
Mr Thaksin alleged there was a plot to kill him
The move angered many, mainly urban Thais, who complained that the family avoided paying tax and had passed control of an important national asset to Singaporean investors.
It led to mass protests and calls for the resignation of the prime minister, who was already under pressure over his handling of a Muslim insurgency in the south and his extensive control over the media.
In a bid to tackle the crisis, and to show he still had widespread public support despite regular massive street protests in Bangkok, Mr Thaksin dissolved parliament in February and called a snap election for April.
Mr Thaksin's Thai Rak Thai party won 57% of the vote in the April election, but millions of Thais cast protest votes and the opposition refused to take part.
After weeks of limbo, Thailand's highly-revered King Bhumibol Adulyadej called the situation a "mess" and ordered the courts to sort it out.
The election result was ruled invalid by the Constitutional Court and a new date was set for later this year.
Mr Thaksin took a seven-week break from politics following the election, but came back to work in May.
The atmosphere has remained tense ever since.
The Thai media has speculated about dissatisfaction towards Mr Thaksin within the military, which is traditionally very loyal to the king.
There has also been talk of a split within some parts of the army, following an annual reshuffle which saw some officers with links to Mr Thaksin moved.
The rumours took on a new urgency last month when police intercepted a car driven by a military officer and carrying a large bomb, near the prime minister's house.
Mr Thaksin accused several military officers of plotting to assassinate him.
His opponents accused him of fabricating a story to win him support in the forthcoming election.