I guess I will just give the basic answer I learnt from high school. If you want your eyes free from infection, do not rub your eyes with your fingers or with dirty handkerchief.
Do not expose your eyes to dust or particles, if you going out under the sun wear sun shade. Don't sit close to a standing fan that is not oscillating as it can introduce dirt into your eyes and dry it up causing pterygium.
When you feel like there is a particle in your eyes, rinse with clean water.
Only use recommended eye drops and ointments to treat eye problems.