Self Harm Help

Does anybody know where if I can go if I need immediate help because I’m thinking of self harm while pregnant? I’m 27 weeks & I’m just not feeling like I belong here & I want to get help for the sake of my baby. Can I call my doctor or go in to the hospital & check myself in? Please help you guys I don’t want to do anything stupid.