Urges are common and normal. They are not a sign of failure. Instead, try to learn from them about what your craving triggers are.
Urges are like ocean waves.
They get stronger only to a point, then they start to go away. If you don't use, your urges will weaken and eventually go away. Urges only get stronger if you give in to them. You can try to avoid urges by avoiding or eliminating the cues that trigger them. You can cope with urges by - Distracting yourself for a few minutes.