Last active
December 27, 2021 21:49
-
-
Save philhawksworth/7b12a0785266f8dcf1960d2df93dfc59 to your computer and use it in GitHub Desktop.
Simple example of Netlify _redirects file
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Redirect with a 301 | |
/home / 301 | |
# Redirect with a 302 | |
/my-redirect / 302 | |
# Rewrite a path | |
/pass-through /index.html 200 | |
# Invisbily proxy to a third party API | |
/api/* https://api.example.com/:splat 200 | |
# Show a custom 404 for a path | |
/special-offer /too-late-its-over 404 | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment