I am 32 weeks pregnant, and I have an infection in my mouth maybe gingervitis, is it safe to take amoxil (amoxicillin) 500mg?

Yes, but. You need to call your dentist to find out what the infection is. Amoxicillin is safe but you should consult with someone who can diagnose the problem and resolve it. Get in soon too.