The first electric execution was carried out in New York in 1890: the condemned man was William Kemmler, who had axed his wife/girlfriend to death. The chair used to kill him (pictured at left) was invented by a Buffalo NY dentist named Alfred Southwick, after a series of botched hangings made people question the humaneness of execution in general. The chair was inspired by his dental chair.
As it happened, the development of the electric chair coincided with the "War of Currents" between the camps of Thomas Edison and Nikola Tesla, to see whose system of electricity would win out. The Edison company (which developed direct current (DC)) advocated for the use of Tesla's alternating current for the chair, to try to make sure that the public associated AC with death. Edison participated in the electrocutions of numerous dogs and horses in his attempt to defeat Tesla and Westinghouse.
Although electric execution was developed as a "humane" alternative to hanging, the execution of William Kemmler took about eight agonizing minutes. Witnesses said it was a horrible spectacle and it would have been better just to use an axe.
The bizarre contraption described in Lovecraft and DeCastro's story reminded us of Hugo Gernsback's Isolator, invented in 1925. Gernsback was an ardent science and technology buff who founded, among other things, Amazing Stories magazine and gave the science fiction genre its first home.