Various game controllers have been specifically created to use it with iOS devices that support MFi (Made for iPhone) controllers, but Sony’s PS3 DualShock 3 controllers don't support it. Running the default iOS 7 operating system, the iPhone and iPad won’t connect to the PS3 controller, but with a new jailbreak tweak it is possible!
Controller For All Cydia TweakThe jailbreak tweak is availble from Cydia’s ModMyi repo and is priced at $1.99. Once you've downloaded Controllers for All, you’ll need to use a utility called SixPair. This utility can be downloaded for the Mac, PC, or for Linux. After you've connected your PS3 controller and the iOS device to your Mac, PC, or Linux box. You’ll need to disable the standard Bluetooth connection on your device.
After Bluetooth has been disabled, start up your MFi controller enabled game, and press the PS button on the face of the PS3 controller when prompted.
Sony has recently revealed that its PS3 DualShock 3 controller will support tablets and smartphones, including Apple products. That may mean that in the future you don't have to jailbreak your iOS product to able to make use of it.
Check out the video below