This post will explain the process to connect any third party controller to your PS5. This method was tested with the following controller models: Xbox Series, Razer Wolverine V2 Chroma and Razer Raiju Mobile. Let's get to it!
For this method to work, you will need to connect your PS5 and smartphone to the same wireless network. Alternatively, you can also directly connect your console to your router via a cable connection, which should significantly improve input latency.
This is an unofficial third party remote streaming app that allows you to connect any controller when streaming a game from your PS5. Unfortunately it's a paid app, but it's totally worth the price.
Simply connect your controller to your smartphone. It's highly recommended to use a cable connection to reduce input latency.
Follow PSPlay setup configuration and make sure to select Local Connect for a more stable experience.
One of the best features of PSPlay is the ability to set custom button mappings, including faking touchpad clicks with your Toggle View/Back button if you're using an Xbox Controller, for example.
Open the app menu and select Button mapping option. You will be redirected to a new setup flow, from here just press the buttons you'd like to use based on the PS Controller image in the screen.
That's it! Happy gaming!