If you choose Erase all Content and Settings (Restore your iPhone, iPad, or iPod to factory settings - Apple Support) it will do just that, erase all data on the device.
If you're simply looking to clear your safari history check out Clear the history and cookies from Safari on your iPhone, iPad, or iPod touch - Apple Support