First method:
- Remove and insert the battery.
- Press and hold together Volume Up + Home + Power button.
- When you see the logo Samsung release Power button.
- When you see little man Android release the rest of buttons.
- Then if you see recovery menu select option "Wipe Data/Factory Reset" with Volume buttons and confirm with Power button.
- Scroll down to "Yes -- delete all user data" and confirm with Power button.
- If the operation is completed select "Reboot System".
Second method:
- Turn on the phone by using the Power button.
- Go to Settings and then to Backup & Reset.
- Tap Factory data reset.
- Choose Reset phone and select Erase everything.
- Well done!