now-redirect is a 𝚫 now CLI tool for easily deploying redirects like
A single command generates and deploys an app that redirects all requests to one URL to another URL. DNS for these domains must already be configured for zeit.world.
npm install -g now now-redirect
From any folder:
# Generate & deploy app that redirects all inbound requests to www.example.comnow-redirect www.example.com# Alias deploymentUrl from the previous command to the URL that needs redirectednow alias [deploymentUrl] example.com# Congrats! Requests to example.com will be redirected to www.example.com
You can swap
example.com if you wish requests to
www.example.com be redirected to