How to Flash Stock Firmware
No need to be rooted and this will not void your warranty. If you are rooted you will loose your root access that’s why this method is also called UNROOT.
1. Backup everything that you need.
2. Make sure your battery is at least 50%.
3. Make sure Samsung USB Driver is installed.
4. Enable USB Debugging (Settings/General/Developer Options). If Developer Option is hidden in your Settings go to Settings/General/About Device and tap the Build Number at least 7 times (if I’m not mistaken).
5. Uncheck Reactivation Lock on Settings/General/Security.
6. Extract the downloaded stock firmware zip file. It must be a tar.md5 file.
7. Turn off your device and go to Download Mode (Volume Down + Power Key + Home Button and then press Volume Up)
8. Connect your device to the PC using usb cable.
9. Run Odin as Administrator. Be sure that the box below the ID COM is color yellow or blue. Click AP or PDA and select the tar.md5 file. Tick the Phone Bootloader Update.
10. Hit Start and wait for the Odin to show PASS before unplugging your device on the PC.
If you got stuck in a bootloop, remove the battery. Go to recovery (Volume Up + Power Key + Home Button). Wipe Data/Factory Reset, Wipe Cache Partition and go to Advance then Wipe Dalvik Cache. After wiping everything go back to the main page of recovery and Reboot System Now.