A story involving Yaoshan is frequently referenced in the writing of Dōgen, the founder of the Sōtō school in Japan. The story is as follows:
Once, when the Master was sitting, a monk asked him, "What are you thinking of, [sitting there] so fixedly?"
The master answered, "I'm thinking of not thinking (思量箇不思量底 sīliàng gè bùsīliàng [Japanese: fushiryō] dǐ).”
The monk asked, "How do you think of not thinking?"
The Master answered, "Nonthinking (非思量 fēi sīliàng [Japanese: hishiryō])."
— Transmission of the Lamp,
According to Carl Bielefeldt, a religious studies professor at Stanford University, this passage encapsulates the essence of Dōgen's teaching on zazen. Because of this, it is referenced frequently in his works, such as in the Shōbōgenzō, Eihei Kōroku, and most prominently his early work the Fukan zazengi.
In another passage;
One day, as Yaoshan was sitting, Shitou asked him, “What are you doing here?”
Yaoshan said, “I’m not doing a thing.”
Shitou said, “Then you’re just sitting leisurely.”
Yaoshan said, “If I were sitting leisurely I’d be doing something.”
The epitaph records his teaching as thus:
“The numinous mind is pure by itself, but it is obscured by phenomenal appearances. If you can dismiss all phenomena, there will be no dual things.”
This teaching emphasizes the pure mind of self nature, which had been a general concept since the early Chan.