We have invented a novel all-optical-logic microfluidic system which is automatically controlled only by visible or near infrared light with down to submilliwatt power. No electric power supply, no external or MEMS pump, no tubings or connectors, no microfluidic valves, nor surface patterning are required in our system. Our device only consists of a single-layer PDMS microfluidic chip and newly invented photoactive nanoparticles. Our photoactive nanoparticles are capable of converting optical energy to hydrodynamic energy in fluids. The nanoparticle themselves are biocompatible and can be biofunctionalized. Via these photoactive nanoparticles, we used only light to drive, guide, switch and mix liquid in optofluidic logic circuits with desired speeds and directions. We demonstrated the optofluidic controls in transportation of biomolecules and cells.