Question: how to setup a wireless keyboard on ps4?
Answer: From the Dynamic Menu's Home Screen, press UP on the d-pad.
Choose [Settings] > [Devices] > [Bluetooth Devices]. ... 
Follow the normal pairing process of the Bluetooth device you wish to pair and enter the passkey (if necessary).