The army has also granted itself wide-ranging powers to enforce its decision.
The military, which last took power in 2006, stated that the move, which gives the army control of nationwide security, was not a coup. Martial law comes after a long-running political crisis, and months of escalating tensions between the government and the opposition.
The chief security advisor to the interim prime minister said the government had not been consulted about the army's decision."Everything is normal except the military is responsible for all national security issues," said Paradorn Pattanatabut.
Reports on social media say soldiers have taken over television stations.
An announcement on military-run television said that martial law had been imposed "to restore peace and order for people from all sides". The public do not need to panic but can still live their lives as normal," the announcement said.
Thailand is mired in political mayhem, with the opposition demanding that power be handed over to an unelected administration charged with rewriting the constitution. The military statement was signed by army chief Prayuth Chan-Ocha, citing a 1914 law that allows it to intervene during times of crisis. It said that the move had been taken because mass rallies between political rivals "could impact the country's security and safety of the lives and properties of the public".
On Monday acting Prime Minister Niwatthamrong Boonsongphaisan insisted his government would not resign, resisting pressure from anti-government protesters.