Molecular nanostructures may constitute the fabric of future quantum technologies, if their degrees of freedom can be fully harnessed. Ideally one might use nuclear spins as low-decoherence qubits and optical excitations for fast controllable interactions. Here, we present a method for entangling two nuclear spins through their mutual coupling to a transient optically excited electron spin, and investigate its feasibility through density-functional theory and experiments on a test molecule. From our calculations we identify the specific molecular properties that permit high entangling power gates under simple optical and microwave pulses; synthesis of such molecules is possible with established techniques.