Express.js · Function
res.redirect
res.redirect() sends the client to another URL. It uses 302 Found by default, or a status code that you provide.
Last updated
- Since
- 4.6.0
Syntax
res.redirect([status], path)In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.
SubscribeRelated
res.location()res.send()req.get()