Best practices for DIY sensors and connecting them to home assistant

Apologies for this vague question, but I am hoping the community can point my ship in the right direction.

I am thinking of making some sensors (e.g. temperature sensor and “window open” sensor). I am wondering what “best practices”, or even “good practices”, or even “practices that have successfully been used in the past” are for integrating such sensors into Home Assistant.

I am planning to build the sensors around either the ESP8266 wifi board or arduino trinkets with NRF24 radio frequency transceivers. My first question is whether either platform is definitively simpler to work with in your experience, or are they potentially equally straightforward depending on my own experience/expertise/willingness to learn/etc?

Where I am most fuzzy though is how to make the connection between the sensor and Home Assistant? I presume I would either setup a home gateway to receive signals from the sensors and serve those signals to home assistant, or use a cloud based iOT gateway that has an integration with home assistant.

What would be a typical home gateway? An arduino directly connected to IO pins of my raspberry pi (which is my home assistant server) as documented here or (here)[MySensors - Home Assistant]?

Alternatively, it seems the ESP8266 can communicate directly to cloud servers (via my home WiFi). This seems a fair bit simpler as if I understand correctly, all I need is an ESP8266 and a wifi connection. The drawback is that this solution is cloud dependent, and if my internet goes down, my sensors are dead. But are any of you using a cloud based iOT solution with ESP8266 and home assistant? What cloud based iOT services have you had success with along with Home Assistant?

Thank you for any pointers you can provide!

Eric

Use ESP-Home and ESP based devices.
They integrate very nicely and locally to HA, and is super simple to configure.

Nice. That looks like just what I am looking for. Almost looks too easy, but I’ll get over it. :laughing: Thank you!