Mahāassapurasutta

Suttapiṭaka · Majjhimanikāya · Vol. 12 · Section 476

[476] With his mind (citta) thus concentrated (samāhita), purified, cleansed, unblemished, rid of defilements, malleable, wieldy, steady, and attained to imperturbability, he directs and inclines the mind toward the knowledge (ñāṇa) of the passing away and reappearance of beings. With the divine eye (dibbacakkhu), purified and surpassing the human, he sees beings passing away and being reborn—inferior and superior, fair and ugly, gone to a good destination, gone to a bad destination … he understands beings as faring according to their kamma. Just as, Bhikkhus, there might be two houses with doors, and there a man with good eyesight, standing in between, would see people entering a house, leaving it, walking to and fro, wandering along, and roaming about; even so, Bhikkhus, with the divine eye, purified and surpassing the human, a bhikkhu sees beings passing away and being reborn—inferior and superior, fair and ugly, gone to a good destination, gone to a bad destination … he understands beings as faring according to their kamma.

English translation from the Pali (Siam Raṭṭha edition) — under review, not for citation.

This passage also appears in 5 other places