Kenya's political parties have been banned from sending any bulk text messages to voters without the approval of state regulators.
The move is intended to prevent parties from sending out hate messages during next year's elections, the state regulator said.
More than 1,000 people were killed in ethnic violence that hit Kenya after the 2007 disputed elections.
Some analysts say hate-filled text messages helped fuel the conflict.
Francis Wangusi - the director-general of the regulatory body, the Communications Commission of Kenya (CCK) - said parties would have to submit to it bulk text messages for vetting 48 hours before sending them out.
He said parties could send the messages in the two main languages - English and kiSwahili - and not in any of the other languages spoken among Kenya's ethnic groups.
'In good faith'
"Any offence that will be committed as a result of sending bulk political messages over the networks... will be punished," Mr Wangusi added.
The Orange Democratic Movement (ODM) - led by Prime Minister Raila Odinga, whose defeat in the 2007 presidential poll triggered the violence - cautiously welcomed the decision.
"If someone has an ulterior motive for wanting to read the content of our messages to our people, and trying to use them against us, we will not accept that," said ODM spokesman Philip Etale.
"But we believe it is in good faith, and it is going to help us curb hate speech and incitement among Kenyans."
Deputy Prime Minister Uhuru Kenyatta's The National Alliance (TNA) party said the guidelines would help ensure that the elections took place peacefully.
"They [the CCK] should have done it sooner," said party spokesman Machel Waikenda.
Mr Kenyatta - who is a presidential candidate - has been charged with war crimes by the International Criminal Court after being accused of fuelling the conflict that hit Kenya after the 2007 poll.
His trial is due to start after the election in March. He denies any involvement in the violence.
Mr Odinga is running again for the presidency.
He entered into a power-sharing government with Mr Kibaki in 2008 to end the post-election violence.
He had rejected the outcome of the election, saying it had been rigged.
Mr Kibaki is stepping down next year at the end of his second and final term.