Loches is about 40 km south of Tours, which is the nearest city with good rail connections to Paris (about an hour by TGV). From Tours, there are trains to Loches (around an hour, with one change at Cormery or direct on some services) and buses that take roughly the same time. By car, the drive from Tours takes around 45 minutes on the D943, a pleasant road that follows the Cher and then the Indre.
If you are combining Loches with other Loire chateaux, a car is strongly recommended. The southern Loire — Montpoupon, Chenonceau, Azay-le-Rideau — is difficult to cover by public transport.