raspi-config P4 only allows temperatures above 60, but I prefer being able to touch my pi before the fan turns on. Is there a way to ignore this limit and set the temperature to a lower value?

2 Answers 2


Only a single line needs to be added to config.txt


to switch the fan on at 60℃ - 60000 millicelcius (the default is 55℃ but you can select any temperature). The fan turns off when the temperature falls by 10℃.

This uses the gpio-fan overlay (which has been available in the kernel since late 2018) and should be included in recent versions of Raspbian. (Read /boot/overlays/README for description of this and other Device Tree overlays.)

See https://raspberrypi.stackexchange.com/a/105820/8697


Reading the code in raspi-config, it sets the following in config.txt


replace x with the gpiopin the fan control is connected to
replace y with the trigger temperature in millicelcius

If you've played with the P4 already you should see the dtoverlay=gpio-fan line in config.txt already, so you just need to edit that and reboot

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.