The Cannabis plant produces a resin containing high percentages of cannabinoids: these phytochemicals are usually formed by 21-carbon atoms and are exlusively present in this genus of flowering plants. Delta-9-tetrahydrocannabinol (THC-9 or Δ9-THC) is the most well-known and psychoactive phytocannabinoid, but more than 100 cannabinoids have been reported by now to be present in different concentrations in cannabis chemovars, each one with specific medicinal effects. Cannabinoids isolated from cannabis include tetrahydrocannabivarin (THCV), cannabidivarin (CBDV), cannabigerol (CBG), cannabidiol (CBD), cannabigerovarin (CBGV), cannabinol (CBN), cannabichromene (CBC), the acidic forms of THC-9 and CBD (respectively THCA and CBDA), Delta-8-tetrahydrocannabinol (THC-8 or Δ8-THC), etc. 
A lot of therapeutic benefits are tought to arise from THC-9 and CBD, but recent clinical and scientific works hilighted the important role of minor cannabinoids. In particular Δ8-THC is gaining particular interest for its ability to excert similar action to THC-9 in terms of appetite stimulation and pain reduction, but bearing lower psychoactive impact. Δ8-THC structure is closely related to the one of THC-9: the only molecular difference is the position of the double bond in the cyclohexene ring, making these molecules isomers and leading to differences in the interaction with CB1 and CB2 receptors. The potency of Δ8-THC is half of his isomer in a lot of measures of biological activity and it binds less efficiently to cannabinoid receptors than THC-9. 
Δ8-THC is present in low percentages in plants but some chemovars have been developed and bred to produce higher amount of it.
In terms of safety it is better to consume hemp-derived Δ8-THC coming from a safe and reliable source: because this molecule can also be obtained in the laboratory modifying CBD with heat and acids, the consultation of the certificate of analysis is always recommended in order to be sure about the residues levels in the final product.
In US, Δ8-THC products legality is sometimes ambiguous: in some states Δ8-THC is considered as CBD products, which are legal if they contain less than 0.3% of THC-9 according to the 2018 federal agricultural act. Conversely, some states have interpreted differently the law and started to introduce restrictions to Δ8-THC commercialization.  It is matter of time to see how the legality of this valuable cannabinoid will evolve.
References: Aizpurua-Olaizola, O. et al. Evolution of the Cannabinoid and Terpene Content during the Growth of Cannabis sativa Plants from Different Chemotypes. Journal of Natural Products, (2016) 79(2), 324–331.doi:10.1021/acs.jnatprod.5b00949 [Journal Impact Factor = 4.257] [Times cited = 309]
 Shahbazi, F. et al. Cannabinoids and Cannabinoid Receptors: The Story So Far. iScience, (2020). 101301. doi:10.1016/j.isci.2020.101301 [Journal Impact Factor = 5.08] [Times cited = 11]
 Pertwee, R. G.. The diverse CB1and CB2receptor pharmacology of three plant cannabinoids: Δ9-tetrahydrocannabinol, cannabidiol and Δ9-tetrahydrocannabivarin. British Journal of Pharmacology, (2008) 153(2), 199–215. doi:10.1038/sj.bjp.0707442 [Journal Impact Factor = 7.73] [Times cited = 1498]