There are many circumstances that can lead to a termite infestation in your home. Some of which you can control and others that you can not.
Subterranean termites look for areas where wood contacts the earth.
However, a direct earth to wood contact is not necessary for this type of termite to infest your home. Sometimes just a crack in your foundation is enough for this species to find your home and begin destructive damage. Most termites species are assisted by the conducive conditions mentioned above. Check your home regularly to avoid opportunity to invite termites into your home. Better yet have a professional inspection done at least every two years.