Code Require for Arduino UNO R3 connected with esp8266 wifi and 2 channel relay

I have tried many internet solutions but failed

If you really want help and not someone to do the work for you, post one of your attempts at coding along with a description of what the code actually does and what you expect the code to do and we can help you to get it working. Please include a schematic of the wiring of the project.

Please read the "how to use this forum-please read" stickies to see how to post code and some hints on how to ask an effective question (see #7 and 11).