There are no specific dietary restrictions while taking Trimethoprim. You can take Trimethoprim with or without food. Taking Trimethoprim with food or milk can help ease upset stomach sometimes associated with Trimethoprim and other antibiotics.