Towards the end of the first century, the churches in and around Ephesus suffered much tension and conflict because of false teaching (e.g. Rev 2:2-6; cf. Acts 20:17,29-30). Early records indicate that the apostle John lived in Ephesus at this time, and that he wrote his Gospel and three letters partly to counter some of the false views.
The false teaching that John fought against in his first letter was being spread around the churches by travelling preachers. The letter that we know as 2 John was written to counter such teaching. No names are mentioned in the letter, but it seems that ‘the elder’ who wrote it was John the aged apostle, and ‘the elect lady’ who received it was a church whose ‘children’ (members) had so far kept the true Christian teaching (v. 1-4). John wanted them to maintain right belief and right behaviour, and warned that false teaching, if allowed into the church, would ruin it (v. 5-13).