
Within an inch of something/of doing something
Negative outcomes
Often used to describe narrowly avoided bad outcomes or disasters. 
Intensity
Emphasizes the severity or intensity of a situation that was closely avoided. 
Expressing relief
Used for expressing a sense of relief after avoiding a very close call. 