Hadith Forgery

As soon as hadith became a source for understanding religion in the first and second centuries AH, abusing it began and some people began forging hadith. The history of forging hadith (Wad') and falsely quoting from the Prophet (s) and the Infallible (a) dates back to the origin of hadith.
Hadith scholars benefited from the two sciences of Rijal and Diraya as the solution for the mentioned problem and though such sciences they could recognize real and fake hadiths.

In hadith collections, there are hadiths narrated from the Prophet (s) in which he (s) encourages people to narrate his hadiths and not lying and forging hadiths.

On the very day of passing the Prophet (s), in the event of Saqifa and the dialogues recorded there, the Immigrants' (Muhajirun) argument for taking over the caliphate was not a verse from the Qur'an but a hadith from the Prophet (s) with the general idea, saying "the imams are from Quraysh". This shows the key role of hadith since beginning.

Also in reaction to spreading innovative yet heterodox hadiths, 'Ali (a) warned that "in the hands of people, there are true and false hadiths of the Prophet (s)" and then grouped narrators of the Prophet (s) into four:

Hypocrites who intentionally made false quotations from the Prophet (s); those who heard something from the Prophet (s), but they did not keep it perfectly and thus were deluded; those who heard an order or prohibition from the Prophet (s), but they did not receive his abrogating order and the fourth group are those who heard and kept hadiths from the Prophet (s) and handed them over to others.

The historical fact is that companions and followers of them usually added their own understandings of the teachings of the Prophet (s) while conveying them and were not often bound to recording the exact wordings. Also in action, the existence of many hadiths quoted from the Companions about the same events having different wordings is an irrefutable proof for the mentioned approach among the Companions and Followers. This shows that contrary to later scholars, early Muslims did not care about recording exact words of the hadiths. This problem is much less among shi'a due to the presence of the Infallible (a).

References

The material for this article is mainly taken from جعل حدیث in Farsi WikiShia.