Malaysia and the United States have agreed to make Malaysia a counter-messaging centre to fight extremism.

Malaysia's Prime Minister Datuk Seri Najib Tun Razak when disclosing this after bilateral talks with US President Barack Obama in Malaysia's capital Friday said that they held similar positions in terms of combating violent extremism and both agreed to work closely to make the Southeast Asian region safer.

Najib pointed out that Southeast Asia was not immune from the threat of extremism as there were groups operating in the region and aligned to the IS militant group.

"So we will work closely with the US and like-minded countries to make this region safer and to combat any form of violent extremism," he said at a joint press conference with Obama after the 45-minute bilateral meeting.

Najib said the counter-messaging centre initiative was important because in fighting extremism "not only a military solution is required but winning the hearts and mind of the people".

"That is why is important for us to present the counter narrative, to present the authentic, the true Islam. So people will realise what IS try to represent is a perversion of Islam," he said.