Have a look at the ESP8266.There are plenty of examples and code on the internet. I used a DHT11 connected to the ESP and programmed it with an Arduino. About 20 lines of code IIRC. The DHT11 is cheap to experiment with. I just wanted to see if it can be done and what was involved.
A small PHP program on my webserver reads the values at specific intervals. Not the best way as the ESP does not go in low standby mode. It is not a concern as mine is not battery powered.
A better way will be push mode where the ESP sends the data, then 'sleep' for a certain time period. That is if you want to run on battery power.