Smart gating membranes have drawn much attention due to the controllable pore structure. Herein, a smart gating membrane with dual responsiveness was prepared from bacteria cellulose (BC) grafted with pH- and temperature-responsive polymers. By external stimulation, the average pore size of the membrane can be controlled from 33.75 nm to 144.81 nm, and the pure water flux can be regulated from 342 to 2118 L·m−2·h−1 with remarkable variation in the pH range of 1–11 and temperature range of 20–60 °C. The adjustability of pore size is able to achieve the gradient selective separation of particles and polymers with different sizes. In addition, owing to the underwater superoleophobicity and the nanoscale pore structure, the membrane separation efficiencies of emulsified oils are higher than 99 %. Moreover, the controllable pore size endows the membrane with good self-cleaning performance. This nanocellulose-based smart gating membrane has potential applications in the fields of controllable permeation, selective separation, fluid transport, and drug/chemical controlled release systems.