Mary Shelley's novel Frankenstein exists at the borders of Gothic horror and science fiction. Much of what she wrote in that novel was inspired by actual scientific research and experiments of her era. As the daughter of William Godwin and Mary Wollstonecraft, and the wife of Percy Bysshe Shelley, Mary Shelley was exposed to many of the latest scientific ideas of the time, including the idea that matter might be animated into life through chemical and/or electrical means.
Although the novel does not explain how Victor Frankenstein brings his creature to life, Mary Shelley was inspired by the writings and researches of men like Erasmus Darwin (grandfather of Charles and a friend of Mary's father), Humphrey Davy, Luigi Galvani, and Adam Walker.
In the introduction, Shelley quotes Darwin as saying that the creation of life from animated matter was not impossible. (Image: Erasmus Darwin)
Professor M. Waldman, who instructs Victor in the new creative powers of science, was probably modeled on Sir Humphrey Davy, the pioneering chemist. (Image: Humphrey Davy)
Davy is featured (holding the yellow pot) in this 1802 satirical cartoon by James Gillray below, a satire of the new craze for scientific experiments.
Electrical experiments "animating" dead animals and animal parts, conducted by Luigi Galvani, were another source of inspiration for Mary Shelley. (Image: Galvani)
Percy Shelley's tutor at Eton, Adam Walker, popularized Galvani's work in Britain and argued for a connection between electricity and life. (Image: illustration from Walker's book System of Familiar Philosophy, 1799)
By Shelley's time, the idea that a corpse might be "galvanized" into life by electricity was being mooted, even attempted.
The following image shows an attempt to revive an executed criminal in Scotland by Dr. Andrew Ure, in 1818, the year before Frankenstein was published.