Sort:  

Everything but freshly sterilized things have bacteria and microbes.
IN truth the more exposure one has to bacteria the stronger the immune system. This is part of why animals are so healthy and humans not.
Sterile environments are actually very unhealthy and detract from health rather than improve it.
Not only can dirt have healthy microbes in it but also trace minerals. Most animals eat some amounts of dirt regularly, intuitively knowing that it is healthy.
Of course there are circumstances where dirt could be dangerous, like if it was dirt that had a dead diseased animal lying on it....But why would you eat dirt like that???
Also there are plenty of solutions for "bad bacteria" like this post here https://steemit.com/health/@gardenofeden/water-quality-is-really-important-we-share-our-easy-and-effective-options-for-water-purification-which-can-save-your-life-in-the
Blessings~*~

Small amounts won't hurt you usually, and will improve your gut flora, best case scenario.