Answer by Professional Japanese Teacher
What’s the matter? What’s wrong?
どうしたの？ / どうした？
Dooshitano? / Dooshita?
he basic phrase that you can use to ask “what’s wrong” or “what’s the matter” is “どうしましたか dooshimashitaka”. This phrase is more formal and you also hear this question if you visit a doctor. If you are very familiar with your colleague, you may also use the more casual version, “どうしたの? dooshitano?” or “どうした？dooshita?”. In both cases, you should say it with a rising intonation to indicate that it is a question.
You can also say “何（なに）かありましたか nanika arimashitaka” to ask “what’s wrong”. Nanika means “something” and arimashita is the past tense of arimasu, which means “to exist”. So this phrase literally means “was there something (that was bothering you)?”
I hope you will find these phrases helpful.