wp redirect – Why “exit” is needed after wp_redirect?
When you call
wp_redirect it sends redirect HTTP headers, and that’s all the browser needs to redirect, there is no reason to continue executing code.
If you do not
exit, WordPress will continue to run the rest of the page generation sequence, loading all the code, which may confuse the browser, or lead to generating HTML the browser has no interest in, as well as wasting server resources.
Afterall why would you continue loading the page if the server has told you to go to a new location?