The short answer
One craving usually rises, peaks and fades over a span measured in minutes, not hours. People commonly describe the worst of it passing somewhere in the region of five to twenty minutes when they do not act on it.
That number is not a promise and it is not a target. Yours may be shorter or longer, and it will vary by day. The useful part is not the figure; it is the shape. The thing you are standing in has an end built into it.
Why it feels like forever
At the peak, the part of you estimating how long this will go on is the same part that wants it to stop. It is not a neutral witness. Almost everyone overestimates in the moment, which is why watching a clock count up is so often surprising: the number is smaller than the feeling.
This is also why "just wait it out" sounds useless when someone says it to you. Waiting is not the hard part. Believing there is an end to wait for is the hard part, and that belief is much easier to hold when you have watched it happen a few times and can see your own record of it.
One passing does not mean the day is over
Cravings arrive in clusters, often around the same triggers: a time of day, a place, a person, an argument, being tired. Riding one out and then meeting another an hour later is completely ordinary. It is not a sign that it did not work.
What helps while you wait
Decide in advance rather than in the moment. When a craving is at its peak is the worst possible time to try to think of something to do instead, which is why writing it down while calm matters so much more than the quality of the ideas.
Most people do better with something physical and specific, not "distract myself" but "walk to the end of the road and back". And with one named person they can call or message, decided ahead of time, so that reaching out is a single tap rather than a decision.
Two other things worth knowing: a count-up timer is kinder than a countdown, because a countdown quietly sets a target you can fall short of; and rating how strong it is before and after gives you your own evidence, which is far more convincing later than anything anyone else tells you.
If this moment is bigger than waiting it out
In the US, the SAMHSA national helpline on 1-800-662-4357 is free, confidential and open every day. The 988 Suicide and Crisis Lifeline is there if you are in crisis. Neither of them needs you to have a plan or the right words first.