You can easily add more GPIO connections for an ESP8266 using a port expander. This example demonstrates how to do that with a common SPI port expander.
These devices are perhaps a little less common than their I2C equivalents, see :sample:`PortExpander_MCP23017`.