For the sexually unfulfilled woman these days, there are a wide variety of solutions. If re-runs of The Bachelor aren’t cutting it, a plethora of sex toys are available for purchase—most notably the vibrator. These autoerotic tools have become so commonplace that they’ve been openly discussed on daytime talk shows like The View and sold in online religious sex-toy shops. Even Kate Middleton was reportedly spotted purchasing one while she was being courted by her future Prince Charming.

Back in the late 19th century, however, women didn’t have this luxury. Worse, Victorian-era women who experienced everything from the loss of sexual appetite to neurasthenia—fatigue, anxiety, mild depression—were diagnosed with “female hysteria,” and often prescribed a manual “pelvic massage” meant to cause “hysterical paroxysm” in the patient (translation: orgasm) to cure said maladies. The film Hysteria, making its world premiere at the 2012 Tribeca Film Festival, tells the story of the vibrator’s invention.

Directed by Tanya Wexler and set in the Victorian era, the film follows Dr. Mortimer Granville (Hugh Dancy), a disillusioned young physician who is hired as an understudy to Dr. Robert Dalrymple (Jonathan Pryce), a doctor renowned for treating women diagnosed with “female hysteria” via “pelvic massage.” When he’s not being wooed by the doctor’s two daughters—the rebellious Charlotte (Maggie Gyllenhaal) and proper Emily (Felicity Jones)—Granville practices his “pelvic massage” technique, and soon he becomes an expert. In the process, however, he develops carpal tunnel from all the manual labor and seeks a new and improved way to achieve “hysterical paroxysm.” And thus the vibrator is born.

“It’s a feminist fable and a romantic comedy with a man at the center, but it’s all about progressives,” Wexler told The Daily Beast. “As long as there have been orgasms, there have been people trying to give them to each other. The funny thing is that the vibrator was kind of invented for a guy as a laborsaving device.”

The usage of “pelvic massage” to combat “female hysteria,” a diagnosis largely debunked in the early 20th century and no longer recognized today, dates all the way back to Hippocrates in 450 B.C., according to Dr. Rachel Maines, a famed sex historian and author of the seminal 1999 book The Technology of Orgasm. It persisted through the Middle Ages but really seemed to explode during the last quarter of the 19th century, when doctors believed there was an epidemic of hysteria. Dr. Russell Trall, a hydrotherapist in the United States, believed that up to 75 percent of women suffered from “female hysteria,” despite having no way of measuring this statistic.

While “hydriatic massage,” achieving paroxysm through spraying water, was used as early as the mid-1700s in U.S. and U.K. bathhouses, manual “pelvic massage” became an enormously popular medical procedure to combat female hysteria during the Victorian era.

“There was no recognition, except by the French physician Raymond Tripier and the 17th century physician Nathaniel Highmore, that there was anything sexual about this ‘paroxism’ at all,” Maines told The Daily Beast. “You’re producing a crisis of the disease, just like the breaking of a fever, and it was simply your duty as a doctor.”

And achieving “hysterical paroxysm” in female patients was a very time-consuming task, with doctors of the era claiming it was incredibly difficult to learn and would take up to an hour manually.

While the electromechanical vibrator was invented by Dr. Joseph Mortimer Granville in sometime in the late 1800s, a steam-powered vibrator, called “The Manipulator,” was invented in 1869 by American physician George Taylor. According to Dr. Maines, the patient-interface component was about the size of a dining room table, and had a cutout area for a vibrating sphere. And the steam engine that powered the reciprocating motion of the sphere was located in a separate room from the patient.

“Doctors didn’t like it because you couldn’t move it and take it with you on a house call, and they also didn’t enjoy shoveling coal into it,” says Dr. Maines, with a laugh.

Dr. Granville’s electromechanical vibrator was portable but had a wet cell battery that weighed about 40 pounds, in addition to the vibrator itself and the Vibratodes. Still, these early vibrators reduced the time it took to achieve “paroxysm” in female patients from an hour to around five minutes.

Battery-powered vibrators were introduced as a household appliance as early as 1899, according to Dr. Maines, but doctors were still trying to convince patients it was worth $2-$3 a visit to be treated by gigantic “pelvic massage” machines, including The Chattanooga, a massage contraption on wheels that stood about 5 feet tall.

“After a while, patients realized that if they could order one from Sears for $5, why should the go to the doctor for $2 to $3 a visit?” she says.

The vibrator was enormously popular, and became the fifth electrical appliance to be introduced into the home, alongside the teakettle, sewing machine, fan, and toaster, and ads for the device ran in everything from Needlecraft and Sears, Roebuck and Co. to Woman’s Home Companion. One 1910 vibrator ad, titled “Vibration Is Life,” reads:

The secret of the ages has been discovered in Vibration. Great scientists tell us that we owe not only our health but even our life strength to this wonderful force. Vibration promotes life and vigour, strength and beauty...Vibrate Your Body and Make It Well. YOU Have No Right to Be Sick.

By the end of the 1920s, however, vibrators began to appear in pornographic films, which made it difficult for women to maintain they were merely buying these devices to massage their scalp or the back of their neck, and doctors dropped them too because of their perceived sexual connotation.

During the Great Depression, the sales of all electrical appliances dropped, and during World War II, the metal used in electrical appliances was diverted into the war effort, so things like vibrators and toasters weren’t really being mass-produced, except for the military, who “didn’t really need the vibrators,” says Dr. Maines with a chuckle. Then, in the 1950s, vibrators were marketed to women with a great deal of “social camouflage.” Dubbed “Spot-Reducers,” they were allegedly used to help women lose weight. Thanks to the 1953 Kinsey Reports, the sex therapy profession gained steam in the late 1950s and, according to Dr. Maines, a sex therapist devised a new way to gain results in his inorgastic patients.

“He discovered his patients were getting great results with vibrating electric toothbrushes and published those results,” says Dr. Maines. “Of course, sales of electric toothbrushes seem to have increased.”

During the 1960s and ’70s, the vibrator resurfaced thanks to feminists like Betty Dodson, who made it a symbol of female sexuality, as well as the publication of the bestselling book The Joy of Sex in 1972. These vibrators were “more like vibrating dildos” and, according to Dr. Maines, were mostly purchased as gifts for women by men, as it was viewed as taboo for women to enter porn shops. These vibrators were advertised in periodicals like Popular Mechanics and Technical World, but not in women’s magazines, a policy that holds to this day.

“I heard back in 2000 that magazines like Glamour and Vogue wouldn’t accept vibrator advertising because they don’t want to endorse female masturbation, although they do accept ads for Viagra,” says Dr. Maines. “It’s heteronormativity, where the only real sex is penetration of the vagina by the penis to male orgasm and everything else is just fooling around.”

The sex toy industry really took off in the 1980s, and vibrators began notching massive sales, which Dr. Maines attributes to baby boomers entering their 30s and realizing, “Well, sex is a part of life, and it’s not something you have to pretend you’re not doing.” Couples even began to go shopping for sex toys together, a practice common to this day.

In 2003, a federal appeals court ruled that a Texas law making it illegal to sell or promote “obscene devices,” punishable by up to two years in jail, violated the 14th Amendment of the Constitution, or the right to privacy. However, the Alabama Supreme Court in 2009 upheld the Anti-Obscenity Act of 1998, which criminalized the sale of sex toys. Alabama today is the only state in the U.S. to outlaw the sale of sex toys, including vibrators.

“They got tired, however, of being an international laughingstock and stopped enforcing it,” laughs Dr. Maines. “The selling of vibrators is illegal, but buying vibrators isn’t illegal unless you buy more than five of them. And it was never clarified if they had to be the same kind of vibrator, or if you were still guilty if you bought, say, an inflatable doll and four vibrators.”

In 2009, a research team behind the landmark 2010 National Survey of Sexual Health and Human Behavior released a study analyzing vibrator usage in U.S. women. Of the 2,056 women aged 18-60 who participated in the survey, 52.5 percent claimed to have used a vibrator.