Thermomagnetic avalanches in superconducting films propagating extremely fast while forming unpredictable patterns, represent a serious threat for the performance of devices based on such materials. It is shown here that a normal-metal frame surrounding a selected region inside the film area can provide efficient protection from the avalanches during their propagation stage. Protective behavior is confirmed by magneto-optical imaging experiments on NbN films equipped with Cu and Al frames, and also by performing numerical simulations. Experimentally, it is found that while conventional flux creep is not affected by the frames, the dendritic avalanches are partially or fully screened by them. The level of screening depends on the ratio of the sheet conductance of the metal and the superconductor in the resistive state, and for ratios much larger than unity the screening is very efficient.