diff --git a/esphome/components/fan/fan.cpp b/esphome/components/fan/fan.cpp index 25f710f893..82fc5319e0 100644 --- a/esphome/components/fan/fan.cpp +++ b/esphome/components/fan/fan.cpp @@ -177,6 +177,10 @@ optional Fan::restore_state_() { return {}; } void Fan::save_state_() { + if (this->restore_mode_ == FanRestoreMode::NO_RESTORE) { + return; + } + FanRestoreState state{}; state.state = this->state; state.oscillating = this->oscillating;