app.get('/redirect', function(req, res) { var string = encodeURIComponent('something that would break'); res.redirect('/your/redirection/url/?data=' + string); });