Given the choice between tossing back a dose of medicine and pushing it through your flesh inside a cold, steel needle, most people pick the pill. Convenience, portability, and lack of skin-stabbiness have made pills the most popular way to administer drugs for the better part of medical history. But not all drugs can survive the corrosive, churning trip from the stomach into the intestines and across to the bloodstream. Antibodies, proteins—these molecules are too fragile. That’s why you still have to get your immunizations as shots, and why many diabetics have to inject themselves multiple times a day with insulin to keep their blood sugar levels from getting toxic.

But there might be another way, if you ditch all your assumptions about what makes a pill a pill and a shot a shot and apply some crazy engineering to the question. Start with an insulin dose, freeze-dry it and compress it into the shape of a needle—you need that shape to get the drug into the bloodstream. Spring-load it into a blueberry-sized pill, so it can be swallowed. Spend some time contemplating charismatic reptiles, and make some design tweaks. Voila, you have a swallowable version of an insulin injection. That was roughly the process of a team of researchers led by Massachusetts Institute of Technology, who published their innovation in drug delivery today in the journal Science.

It’s not just another wild science experiment from the same lab that created this medieval, microneedle-studded masterpiece a few years ago. The work is part of a collaboration with Danish drugmaker Novo Nordisk, the world’s biggest supplier of insulin. They expect to be testing the capsule in humans within the next two to three years.

“The preliminary plans look very promising,” says Lars Fogh Iversen, Novo Nordisk’s senior vice president of global research technologies. “However, it’s early days and more work has to be conducted. We have not yet decided which molecule will be the right one for the first clinical trials.” According to Fogh Iversen, the company is considering other areas besides diabetes, including obesity, haemophilia, and growth hormones.

The pharmaceutical firm first approached the MIT team in the fall of 2014, following the publication of their first attempt at a needle-in-a-pill-pack. Intrigued by the possibility of offering a much easier, pain-free way to dispense its chief product, Novo Nordisk began backing the project in mid-2015, providing grant funding, materials, and scientists. From the beginning, that meant that the engineering couldn’t just be about what worked in a lab. Only concepts that could scale up to commercial manufacturing were considered.

The first problem the researchers had to solve was one of orientation. The group’s previous version had microneedles arrayed in 360-degree fashion to inject their insulin dose into the close-quartered walls of the small intestine. In studies with pigs it injected just fine, but it was hard to predict when and where in the gut that would happen. To achieve a faster-acting, more reliable dose, the researchers decided to rejigger their design to work exclusively in the stomach. But in that more cavernous organ, the shape and layout of their needles would have to change. They needed to make sure 100 percent of the needles made contact with the lining of the stomach. That also implied the pill couldn’t just tumble in free-fall. “We thought at first we might borrow from the Weeble Wobble,” says Giovanni Traverso, a gastroenterologist at Brigham and Women’s Hospital and Harvard Medical School and senior author on the paper. But the round-bottomed children’s toys were designed to be pushed over, they realized, “and we wanted something that once it righted itself would stay that way.”