CBD buds of chocolate by Chronic Candy are displayed at the Big Industry Show at the Los Angeles Convention Center, Aug. 31, 2018

The agency wants data on CBD's safety in food products and feedback on how it might regulate manufacturing, marketing and labeling, according to a notice posted Tuesday in the Federal Register.

The Food and Drug Administration has set its first public hearing on legalizing CBD in food and drinks, to figure out how to regulate the newly legalized cannabis product. The hearing will take place on May 31.

"It's critical that we address these unanswered questions about CBD and other cannabis and cannabis-derived products to help inform the FDA's regulatory oversight of these products — especially as the agency considers whether it could be appropriate to exercise its authority to allow the use of CBD in dietary supplements and other foods," Gottlieb said in a statement Tuesday.

For more on investing in health care innovation, click here to join CNBC at our Healthy Returns Summit in New York City on May 21.

CBD, short for cannabidiol, is a non-psychoactive compound found in the cannabis plant that promises to relax the body without altering the mind like THC. Congress legalized CBD derived from hemp in December.

This was supposed to lead to a surge in consumer products infused with the cannabis compound. However, the FDA's rules prohibiting the addition of CBD to food and drinks have kept most large companies on the sidelines, though a number of start-ups have jumped in anyway.

Facing calls from Congress, the FDA has privately been searching for a solution. It will now take its efforts public, first with the meeting, which will take place at its headquarters near Washington, D.C. Gottlieb said the working group plans to share its findings as soon as this summer.

"This is a complicated topic and we expect that it could take some time to resolve fully," he said. "Nevertheless, we're deeply focused on this issue and committed to continuing to engage relevant stakeholders as we consider potential paths forward."

The FDA and the Federal Trade Commission on Tuesday issued warning letters to three companies — Advanced Spine and Pain's Relievus, Nutra Pure and PotNetwork Holdings — for allegedly making unproven claims about their CBD products, such as helping to treat cancer and Alzheimer's disease.

"The FDA continues to be concerned about the proliferation of egregious medical claims being made about products asserting to contain CBD that haven't been approved by the FDA, such as the products and companies receiving warning letters today," Gottlieb said.

Nutra Pure President CJ Montgomery in an email to CNBC said that compared with "many other CBD-related companies making over-the-top health claims," the language his company used was "quite minor." He said the company removed the language "out of an abundance of caution" but is "still seeking affirmation from the FDA on the few remaining issues."

The other two companies did not immediately respond to CNBC's request for comment.