THC is the primary psychoactive chemical in marijuana. CBD is another compound that typically is sought after for pain reduction and as a sleep aid. THC is known to mess with REM sleep. If your are looking for information Erowid is a good resource, Reddit can be helpful too.