The Quran condemns all sects. All sects in Islam, whether Sunni, Shias, Ahmaddis, Ismailli......etc have disagreements about hadith and sunnah attributed to the prophet. However, these same sects have no disagreements about the Quran.
It is sources of religious law, stories, conjecture, etc. outside the Quran which have created these sects. At the end of this article three "authentic" hadith have been produced about the last sermon of the prophet. The different versions/conjecture gave rise to sects.
These sects of Islam ( Sunni, Shias, Ahmaddis, NOI....etc.) do exactly the same thing - they follow sources and religious scholars, instead of the Quran.
[6:159] Those who divide themselves into sects do not belong with
you. Their judgment rests with GOD, then He will inform
them of everything they had done.
[30:32] (Do not fall in idol worship,) like those who divide
their religion into sects; each party rejoicing with what
[42:14] Ironically, they broke up into sects only after the
knowledge had come to them, due to jealousy and
resentment among themselves. If it were not for a
predetermined decision from your Lord to respite them for
a definite interim, they would have been judged
immediately. Indeed, the later generations who inherited
the scripture are full of doubts.
The last sermon of the prophet witnessed by the thousands has
three versions. The versions the references are listed below.
1) I leave with you Quran and Sunnah
2) I leave with you Quran and Ahl al-bayt
Muslim 44/4, Nu2408; ibn hanbal 4/366; darimi 23/1, nu 3319.
3) I leave you for the Quran alone you shall uphold it.
Muslim 15/19, nu 1218; ibn Majah 25/84, Abu dawud 11/56.
Because the majority of the Muslims follow conjecture (hadith and
sunnah) instead of Quran alone (17:46) as our Creator has
commanded the "Muslims" are divided into sects. These sects are
there because of differences and disagreements on Hadith rather
than disagreements over the Quran.