Thanks, that website is really useful. It mentions another article and that provides a great explanation of which pin is best to use as in- or output and why:
http://www.thesmarthomehookup.com/post-320/
However that didn’t solve my problem 
For clarification, I’m using a “Wemos” D1 Mini from Aliexpress. It has less pins than the NodeMCU, but the pins that are present and have the same label (D0-D8) are connected to the same GPIO pins as on the NodeMCU, which may be obvious to some but I wanted to cover all bases.