Skip to content
Manage redirects from a single file for static hosting
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.gitignore
.npmrc
gatsby-node.js
index.js
license
package.json
readme.md

readme.md

gatsby-plugin-redirects

Manage redirects from a single file for static hosting.

If you're using a hosting provider that doesn't offer built in redirect support you can use this plugin to create static HTML files with the redirect meta tag.

Installation

npm install --save gatsby-plugin-redirects

Usage

// gatsby-config.js
module.exports = {
  plugins: [
    'gatsby-plugin-redirects'
  ]
}

Then create a redirects.json file in the root of your project:

[
  {
    "from": "/old/path",
    "to": "/new/path"
  }
]

Related

License

MIT

You can’t perform that action at this time.