What does the factory reset button do?
A factory data reset erases your data from the phone. While data stored in your Google Account can be restored, all apps and their data will be uninstalled. To be ready to restore your data, make sure that it's in your Google Account.
What does factory reset include?
A factory reset restores a computer, smartphone, etc. back to the state it was in when it left the factory. This includes deleting all of the data, apps, and settings that the user changed on the device. The next person to use it should have the same experience as when it was first unboxed.