Wiping personal info is definitely important, but let me give you some advice on selling your phone. When you go to sell your phone, do not allow sell your phone to anyone outside the US! I listed my old iphone on ebay and the winning bidder was from Russia. I didn't realize I had allowed international bids but I didn't think it was a big deal. I shipped via USPS international which includes tracking and delivery confirmation. Well, the package got "lost" somewhere in Russia according to the tracking. The winning bidder claimed he never received it, so Ebay forced me to give him a full refund even though I had proof that I shipped the phone. Because I couldn't prove delivery, I had to give him a full refund. So now some asshole in Russia has a free iphone donated by me.
When it came time to sell my next phone, I made sure to only allow people in US to bid on it. When the auction completed, the winning bidder asked me to mail it to his address in Israel. Like I'm some kind of fucking idiot. I e-mail Ebay and demanded the auction be cancelled and the fees refunded, and fortunately they agreed. But I will never sell a phone on Ebay again. Either I'm really unlucky or there is a huge scammer market for phones on Ebay. I saw that Amazon offers a program where you get an Amazon credit worth fair market value if you sell your phone to them. After fees, it worked out to about the same as selling on Ebay, so I went with them instead. And this time I actually got paid for my phone!
So don't make the same mistake as me. Check what Amazon will give you and if it's a fair deal, go with them. If you have a death wish and want to sell your phone on Ebay, make sure you only sell in the US, get delivery confirmation, and don't ship via USPS.