301 and 302 are HTTP redirect status codes that both send a browser to a new URL, but they signal very different intent. A 301 says "this moved permanently"; a 302 says "this is temporary, keep using the original." Search engines treat them accordingly.
Getting this wrong hurts SEO. Use a 302 for a permanent move and you may fail to pass link equity to the new URL; use a 301 for a temporary change and search engines may drop the original from their index.
