Oates was born in Oakham, Rutland, and attended Caius College, Cambridge, where he gained a reputation for stupidity and homosexuality. He transferred to St John’s College in 1669 but left without a degree. In 1675, while living in Hastings, he falsely accused a local schoolmaster of sodomy in an attempt to become schoolmaster himself. Oates was accused of perjury, but escaped and fled to London. In 1677 he was appointed as a chaplain of the ship Adventurer in the English navy, but dismissed on suspicion of a homosexual offence.
In 1678 he claimed to have discovered a plot by Roman Catholics to murder King Charles II. This aroused considerable anti-Catholic feeling, but was eventually revealed as a forgery. In 1681 Oates was convicted of sedition and imprisoned. In 1685 he was tried again, this time for perjury, and sentenced to life imprisonment with annual whippings, but he was pardoned in 1688, on the accession of William III and Mary II.