Apple does a great job at keeping your iOS device secure against malicious attacks and unauthorised access. But there are a few steps that you can take to ensure that your private data stays private, and increase the likelihood that you get your device back whether it’s lost or stolen.
Passcode
Setting a passcode for your iOS device is a great first step in keeping your iOS device secure. To set one go to Settings, tap General and then tap Passcode Lock.
Before you Turn Passcode On you should consider whether to turn Simple Passcode off. With Simple Passcode on you will set a 4-digit number, with it off you can set a longer alphanumeric passcode. Longer alphanumeric passcodes are more secure but also a little more fiddly to enter on the lock screen as you'll be presented with the full keyboard instead of the numeric keypad. But here's a pro tip where you can get best of both worlds. If you have Simple Passcode off and set a long passcode that only contains numbers the lock screen will now present the numeric keypad instead of the full keyboard. Now you can choose a longer, more secure numeric passcode which is both easier to remember and quicker to enter that an alphanumeric one.

With your passcode set you’ll now want to consider whether to turn Erase Data on. When Erase Data is on if someone tries to access your device and fails to enter the correct passcode ten times all the data on the device will be erased. If you have very confidential data on your device then this may be a feature you want, but it does come with a couple of draw backs. If you have young children or a friend at the pub trying to guess your passcode they could be unaware of the consequence of guessing it incorrectly ten times. Secondly, if the device is lost or stolen and subsequently erased then it means that you won't be able to use Find My iPhone to help track it down.
Find My iPhone
If you setup Find My iPhone on your iOS device then the chance of getting it back after it's lost or stolen can be greatly increased. You can turn Find My iPhone on by going to Settings and tap iCloud. You can now use any computer web browser to sign in to iCloud to find the approximation location of the device on a map. Alternatively your can use a friends iOS device and Apple's Find My iPhone app available from the App Store.
You can also use the service to make the device display a contact message and play a sound, great if you’ve misplaced your device. You can also remotely lock the device; with a new 4-digit number if you'd previously not set a passcode lock. And if all hope is lost and you really don't want your private data getting accessed you can remotely wipe the device. The downside to this is once performed the device will no longer be able to be located.

Restrictions
Having Find My iPhone enabled offers some great features to help you get your device back, but there is an extra step you can take to help recover your device when it’s stolen. A would be thief could pinch your device, and if the passcode lock is off or not required to unlock until after a long period of time, they could go straight in to Settings and turn Find My iPhone off. To prevent such a tactic you can use device restrictions. Go to Settings, tap General and then tap Restrictions. When you tap Enable Restrictions you will set a passcode lock and can then prevent changes to particular services. Around the middle of the list you will see Location and Accounts, tap on each and set Don't Allow Changes. Now the thief won’t be able to prevent your device showing up on Find My iPhone whilst it's switched on.

Conclusion
We all store a lot of personal data on our iOS devices, probably more than we'd anticipate. Hopefully you’re now a little more aware of some of the measures you can take to help keep your iOS devices more secure. I’d recommend at a minimum that you set a simple passcode for all your devices. Find My iPhone is great and I'd recommend you switch it on too, fortunately I've never had to use it out of anything other that curiosity. Tom Symonds, a Home Affairs correspondent for the BBC, has though and wrote an interesting account of his experience tracking down a thief with the police. If you'd like to read more about the security technologies and features implemented on Apple's iOS devices they have published an in-depth document titled iOS Security.