The characters combine literally and poetically to mean “grass and trees are all soldiers.” The meaning is instantly visual, creating a powerful image of a mind consumed by fear.
The origin of 草木皆兵 is one of China's most famous historical stories: the Battle of Fei River (淝水之战, Féi Shuǐ zhī Zhàn) in 383 AD. The invading Former Qin army, led by Emperor Fu Jian, was said to have nearly a million soldiers and vastly outnumbered the defending army of the Eastern Jin dynasty. However, the Former Qin army was poorly organized and had low morale. The Eastern Jin forces used clever tactics to create chaos, leading to a massive panic among the invaders. As the Former Qin soldiers fled in terror, they looked back at the Bagong Mountain (八公山) and saw the swaying grass and trees. In their panicked state, they mistook these inanimate objects for an endless army of Jin soldiers pursuing them. This psychological collapse sealed their defeat. The story became immortalized in this idiom, capturing the idea that overwhelming fear can make you see threats where none exist.
草木皆兵 is a well-known idiom used in both written and spoken Chinese, though it carries a literary flavor. It's often used to describe someone's state of mind after a traumatic event or in a high-pressure situation.