When going through withdrawal, craving is a psychological urge to administer a discontinued medication or recreational drug.
Craving (withdrawal) Wikipedia
The duration that cravings last after discontinuation varies substantially between different addictive drugs. For instance, in smoking cessation, a substantial relief is achieved after approximately 6–12 months, but feelings of craving may temporarily appear even after many years following cessation.
Cravings may be triggered by seeing objects or experiencing moments that are associated with the drug or usage of it, and this phenomenon, termed post acute withdrawal syndrome, may linger the rest of the life for some drugs. For the alcohol withdrawal syndrome, the condition gradually improves over a period of months or in severe cases years.