Up to 40 million people around the world have Type 1 diabetes, and many of them have to prick themselves with a needle twice a day to ensure their blood sugar levels are in check.

» RELATED: Common vaccine may ease advanced diabetes cases, study finds

But researchers from the Harvard John A. Paulson School of Engineering and Applied Sciences have now developed an oral delivery method that could replace the painful insulin injections responsible for maintaining appropriate glucose levels.

The research was published in the Proceedings of the National Academy of Sciences on Monday.

» RELATED: Scientists say there are 5 different types of diabetes, not just Type 1 and 2

While insulin therapy by injection is effective, "many people fail to adhere to that regimen due to pain, phobia of needles, and the interference with normal activities," senior author Samir Mitragotri said in a news release. "The consequences of the resulting poor glycemic control can lead to serious health complications."

This new oral delivery features insulin-ionic liquid formation encapsulated in an acid-resistant enteric coating. Because insulin doesn’t fare well inside the stomach’s acidic environment, this enteric coating is critical to avoiding breakdown by gastric acids in the gut.

» RELATED: Diabetes after age 50 could be sign of pancreatic cancer, study says

Researchers have previously tried to re-engineer the insulin molecule to resist acidic breakdown and overcome other gastrointestinal obstacles, but there is no oral insulin delivery product currently available in clinic or hospital settings.

"It has been the holy grail of drug delivery to develop ways to give protein and peptide drugs like insulin by mouth, instead of injection," Georgia Institute of Technology professor Mark Prausnitz, who was not involved in the research, added. "The implications of this work to medicine could be huge, if the findings can be translated into pills that safely and effectively administer insulin and other peptide drugs to humans."

» RELATED: Scientists may have found a way to reverse type 2 diabetes

The researchers plan to continue animal testing and are optimistic about human clinical trials.

Approximately 1.25 million American children and adults have Type 1 diabetes, according to the American Diabetes Association.

» RELATED: Loneliness increases your risk of Type 2 diabetes, study suggests

In Type 1 diabetes, the insulin-producing beta cells of the pancreas are "mistakenly attacked and destroyed by the immune system," according to Medical News Today.

And in Type 2, the most common category of diabetes accounting for 90-95 percent of all cases, the body’s cells either stop responding to insulin or the beta cells can’t produce enough of the hormone.

People suffering from either type of the disease have blood sugar levels that can become too high. This condition is called hyperglycemia and can lead to kidney disease, heart disease and more if it’s not properly controlled or treated.

Read the full study at pnas.org.