CBD, or cannabidiol, is one of 113 cannabinoids unique to the hemp plant. CBD is produced by the leaves and flowers of female hemp plants. Hemp is defined as all cannabis plants with less than 0.3% THC by weight. Because hemp has such low THC levels, it is non-psychoactive by definition.
While CBD can be extracted from non-hemp varieties of the plant, hemp-derived CBD is less restricted by the government because of its inherently low levels of THC. CBD from hemp is legal for sale in most US states, while CBD products derived from non-hemp varieties can contain noticeable amounts of THC, and are therefore subject to stricter laws and regulations.
CBD and other cannabinoids are produced by the hemp plant because of their unique aromatic and antioxidant activities, which protect the plant from insects, fungus, bacteria, and changes in the environment.