We demonstrate the feasibility of a photodetector based on an ensemble molecular junction, where a self-assembled monolayer of an organic donor-acceptor dye is directly sandwiched between two electrodes. In such a device, upon photoexcitation and generation of a charge-transfer state on the molecule, charges are dissociated and directly collected at the electrodes without the need of transport through a bulk phase, as in usual photodetectors. We show that the device can work in photovoltaic regime and the spectral response can be tuned by varying the light absorbing dye. Therefore, the electro-optical properties of the downscaled device can be unambiguously related to the physical-chemical properties of the molecules, a commonly difficult point to demonstrate in a molecular junction device, because of the uncertainties of the interplay between molecules and electrodes. The proposed device, which relies on a simple self-assembly process, has a strong potentiality for fast responding, downscaled detectors, ultimately limited by charge dissociation dynamics, and can be considered also as a useful tool to investigate fundamental electro-optical processes in molecular monolayers.