Install the free Remote app and you can use your iPhone, iPad, or iPod Touch to control your Apple TV as long as everything is connected to the same Wi-Fi network. After installing the app, tap the Add Apple TV button to pair the app with your Apple TV.
On your iPhone, iPad, or iPod touch, open the Remote app.
Tap Add a Device.
On Apple TV, open the Settings app.
Select Remotes and Devices.
Select Remote app.
Select the pairable device that your Remote app is on.
Enter the number from your pairable device’s screen.
How do I add Apple TV to my remote app?
How to set up the Remote app Manually