Temperature And Humidity Monitoring System using ThingSpeak

Project Overview:
This tutorial is all about how to log humidity and temperature data on Cloud. We make use of ThingSpeak API which is free. In our previous post We have tried uploading the values to our own locally hosted database. If you haven't checked that out, please give a visit to
In comparison with this, ThingSpeak provides us with a visually interactive Dashboard which is easier for Analysis.

NOTE: This method is not limited to temperature sensing. Same process is applied to obtain data from other sensors

Code is provided at the end of this page

Hardware Required:
  • ESP8266 Microcontroller
  • DHT11 Sensor

  • Connect VCC of the sensor to either Vin or 3V3 supply of the Microcontroller
  • Connect Data out pin to D3 (as per code)
  • Connect both the Ground terminals
Setting up ThingSpeak API
  • Go to https://thingspeak.com/ and Sign up for an Account
  • Create a new channel by filling in the basic details
  • Navigate to API keys in the channel you have created. Make a note of the Write API Key Which will be used in the program
Setting up the Microcontroller

The Program for temperature and humidity monitoring using DHT11 is provided at the end of this page
  • The code is well commented on where the changes has to be made.
  • Make the necessary changes and upload it to the Board
Link to the Code: https://github.com/techxaperture/ESP8266-ThingSpeak