How to factory reset (Erase all user data)

  1. Make sure
    – You are backed up (Settings > System > Backup).
    – And you remember your google password.
  2. Then do Factory reset (Settings > System > Reset options > factory reset)

If touchscreen is not working or broken, then follow Erase User Data Without Touchscreen.