Iran's supreme leader has accused the United States and Britain of creating the militant group Islamic State (IS) to sow rifts between between Sunni and Shi'ite Muslims.

Ayatollah Ali Khamenei said on October 13 that Washington and "the wicked government of Britain" created both IS and Al-Qaeda "to create divisions and to fight against the Islamic Republic," but the militant groups have turned against them.

In his first speech since undergoing prostate surgery last month, Khamenei said efforts by Washington and its allies against IS militants are not genuine.

Both Iran and the United States oppose the militant group that has overrun swathes of Iraq and Syria in recent months.

The United States is leading a campaign of air strikes against Islamic State militants.

The West also supports the rebel forces fighting against Syrian President Bashar al-Assad, a close ally of Tehran.

Based on reporting by Reuters, presstv.com and Khamenei.ir