There are many people out there who want to get a peek in your phone at your private information. If someone somehow got your phone in their hands, would they be able to see your private stuff? If they were able to download your files, could they read them? By putting a passcode on your phone and encrypting it, you'll help keep honest people honest and make the bad guys work a whole lot harder to get anything!
Securing Your iPhone
If you have an iPhone, there are two things to do: Set up a passcode and turn on Find My iPhone. Apple has made it so creating a passcode automatically encrypts all your data. If you erase the phone, it zaps the key that decrypts it, so a person can't even grab data that didn't really get erased and see it without years or decades of hacking to figure out the encryption.
In Settings, choose "Touch ID & Passcode." You'll then get to choose the type of passcode you want. The longer you make it, the better. Even Apple defaults to at least a 6-digit numerical code now, but you can choose longer, or even choose AlphaNumeric and type in a random phrase. It will warn you if what you choose is easy to guess, and once you save it, the iPhone automatically encrypts your data. It takes a while, but it's done efficiently in the background while you go about doing other things.
"Data protection is enabled" should show up at the bottom of the passcode settings when you're done. While you're here, if your iPhone has TouchID, go ahead and set up a couple fingerprints, too. Those are kept in the iPhone "secure enclave" chip away from everything else, so no one is going to get your fingerprints from inside the phone.
If you turn on Find My iPhone, you can see an approximate location of where your phone is by logging into iCloud.Com in a web browser as long as the phone is on and connected to a network. It's handy to give to the police to help them locate a stolen phone. (Don't go after the culprit yourself; many have been hurt that way!) Even if your phone is erased, the phone will be locked and unusable without your ID and password. Just remember to turn off Find My iPhone if you sell or give your phone to someone.
Securing Your Android Phone
When you encrypt your Android phone, your data will be extremely difficult to get to without your password. Even after erasing your phone, bits of your data might remain, but since the decryption key is gone it can take years for even a good hacker to get anything. Make sure your password is long and random for the best security. Depending on the brand and model, your settings may look different than the image below, but you should be able to find a "Security" selection.
Make sure your phone is plugged in, because encrypting in Android will take some time and you won't be able to do anything else while it does. After selecting "Security" you'll see an encryption option you can turn on. It'll ask you to verify a couple times that you really want to encrypt the phone (you do!) and then begin working away.
Once encrypted, someone could still factory reset your phone and use it, so if you wish to protect against that, sign into your Google account to turn on Activation Lock or your Samsung Account to turn on Reactivation Lock. This will make the phone require your ID and password after reset, effectively making the phone useless to would-be thieves. Just remember to sign out of the account if you ever decide to give away or sell your phone to someone!
And You're Set...
There are, of course, even more methods to make your phone even more secure against thieves and threats, but these basic steps included with iOS and Android will work for all but the hardest core hackers out there. They take a few minutes to set up but will give you much peace of mind if you happen to lose your phone one day.