openhab and domoticz are 2 mature and established home automation systems that i am aware of, Both have a growing community of supportive users too. For a slightly quicker start however i opted to start my journey in home automation control with Node Red as a central control system. (still a bit of learning involved tho..)
Instead of connecting input and outputs directly to my Pi Ive chosen to employ wireless coms to receive both sensor inputs and send control commands. the Pi sits as a headless controller, The Node Red Desktop providing a gui web interface.
Using 'smart' sockets with embedded esp8266/5 microcontrollers which are available in plenty of guises you can either write your own firmware and reprogram the devices through a number of routes, such as the arduino-ide, VC/platformio for example, Or as i did use a fully featured open source firmware project. Tasmota https://github.com/arendst/Sonoff-Tasmota/wiki
By the time you factor in the cost of wiring,boxing, and the time it takes to connect things, not forgetting the prime directive of fault finding (Its the bl**dy cable/wiring at fault), wireless is a sensible route enabling a rapid deployment of devices..
For very basic inputs such as PIR, window/door reed switch alarms, and switches, there are many cheap (less than £5) input devices that transmit on the 433mhz frequency, a £8-10 esp8266 based device 'sonoff rf-bridge' can be used to 'bridge' many (not all) 433mhz signals to your wifi network
the diy chique of exposed pcbs and sensors can be a hard sell when trying to install anywhere other than around your workbench area too
For more sophisticated inputs check out hacks for the many bluetooth ble sensors. for example im using the bluetooth temperature and humidity sensors from the chinese Xiaomi brand that will run off a single aaa cell for circa 12-18months
And if you really feel the need to get the soldering iron out you can always add sensors to your smart sockets, if using tasmota there is built in capacity for most sensor inputs you can think of, and if you have one not catered for i sure the developer would be interested in knowing what it is. ..