in one's right mind; sane; of sound mind
Used to describe someone who is mentally sound, not crazy or delirious. Often appears in negative or questioning contexts.
彼は気は確かか?
Is he in his right mind?
あんなことを言うなんて、気は確かじゃない。
Saying something like that, he can't be sane.
The expression combines 気 (mind/spirit) with the topic marker は and 確か (certain/sound). The exact historical derivation is uncertain, but it functions as a set phrase meaning 'of sound mind'.