Illicit and Illegal
23/12/16 The difference between ‘Illicit’ & ‘Illegal’
Unlawful or prohibited. For example, the laws may make it a crime to engage in “illicit trade” or possess “illicit drugs.”
Against or not authorized by the law. Also called illicit or unlawful.
Basically, you will often have to determine whether to use illicit or illegal based on collocation and usage.