Abstract We propose that holographic spacetimes can be regarded as collections of quantum circuits based on path-integrals. We relate a codimension one surface in a gravity dual to a quantum circuit given by a path-integration on that surface with an appropriate UV cut off. Our proposal naturally generalizes the conjectured duality between the AdS/CFT and tensor networks. This largely strengthens the surface/state duality and also provides a holographic explanation of path-integral optimizations. For static gravity duals, our new framework provides a derivation of the holographic complexity formula given by the gravity action on the WDW patch. We also propose a new formula which relates numbers of quantum gates to surface areas, even includ...