There are a few ways to solve your issues.
- the AT command set.
- program the ESP8266 as independent web server, and read the data from the Mega using Serial or I2C communications.
- get an I2C ADC port expander like the ADS1115 and connect everything to the ESP8266 (that way you have the five analog ports you want: four on the ADS1115, one on the ESP8266 - but mind the ESP8266s ADC range is 0-1V), freeing up your Mega for another project.