Edward Jenner is commonly credited with devising a way of immunising people against smallpox by inoculating them with a related disease called cowpox. There’s a well-known cartoon showing the people being immunised sprouting cows from where they’ve been inoculated. Apparently, some farmer called Benjamin Jesty used this means to immunise his wife and children in 1774, twenty years before Jenner made his discovery independently of him.
But I’ve just been formatting the letters that Lady Mary Wortley Montague wrote to various friends as she travelled across Europe to Turkey early in the 18th century. In one written to Mrs S. C. in April 1717, she says
A propos of distempers, I am going to tell you a thing that will make you wish yourself here. The small-pox, so fatal, and so general amongst us, is here entirely harmless, by the invention of ingrafting, which is the term they give it. There is a set of old women, who make it their business to perform the operation, every autumn, in the month of September, when the great heat is abated. People send to one another to know if any of their family has a mind to have the small-pox: they make parties for this purpose, and when they are met (commonly fifteen or sixteen together) the old woman comes with a nutshell full of the matter of the best sort of small-pox, and asks what vein you please to have opened. She immediately rips open that you offer to her, with a large needle, (which gives you no more pain than a common scratch) and puts into the vein as much matter as can ly upon the head of her needle, and after that, binds up the little wound with a hollow bit of shell; and in this manner opens four or five veins.
In other words, the Turks were already using a similar means of inoculating people against the disease, but had been doing so quite some time before. Montague was so satisfied with the results that she decided to have her son immunised and planned to introduce such a treatment to England, although she says
…and I should not fail to write to some of our doctors very particularly about it, if I knew any one of them that I thought had virtue enough to destroy such a considerable branch of their revenue, for the good of mankind. But that distemper is too beneficial to them, not to expose to all their resentment the hardy wight (sic) that should undertake to put an end to it.
Clearly, if Montague did try and disseminate this means of inoculation, then it appears to have been unsuccessful. She herself caught smallpox later in life, but there’s no indication that she had herself immunised in this way.