The half-life of a drug is the time taken for the plasma concentration of a drug to reduce to half its original value. Half-life is used to estimate how long it takes for a drug to be removed from your body.
For example: The half-life of Ambien is about 2 hours.
So if you take Ambien after 2 hours the plasma concentration will be reduced to half, after 2 more hours the remaining blood levels will be reduced by another half - so a quarter will be left. Two hours later another half will be removed leaving one eighth and so on. Generally it is considered that it takes 5.5 half-lifes for a drug to be removed from the body, in that it is considered to no longer have a clinical effect.
So for Ambien it would take approximately 11 hours (2 hours X 5.5) to be eliminated from your body.
Elimination of a drug varies from person to person due to factors like age, weight, other medications taken, or other medical conditions present, also kidney function, liver function etc. Therefore half-life is used as a guide or an estimate of how long it may take for the drug to be removed from the body.
See Also: Drug Half Life Explained
https://www.drugs.com/article/drug-half-life.html