If pain is severe, resulting from trauma, or accompanied by other concerning symptoms, consult a doctor immediately. For general discomfort, if it persists for more than a week without improvement, it's a good idea to seek medical advice.