Abstract. Active feedback of resistive wall modes is investigated using cylindrical theory and toroidal calculations. For tokamaks, good performance is obtained by using active coils with one set of coils in the poloidal direction and sensors detecting the poloidal field inside the first wall, located at the outboard mid-plane. With suitable width of the feedback coil such a system can give robust control with respect to variations in plasma current, pressure and rotation. Calculations are shown for ITER-like geometry with a double wall. The voltages and currents in the active coils are well within the design limits for ITER. Calculations for RFP's are presented for a finite number of coils both in the poloidal and toroidal directions. With 4 coils in the poloidal and 24 coils in the toroidal direction, all non-resonant modes can be stabilized both at high and low theta. Several types of sensors, including radial and internal poloidal or toroidal sensors, can stabilize the RWM, but poloidal sensors give the most robust performance.