您必須設(shè)置ExpressJS頭。 app.use(function (req, res, next) { res.header("Access-Control-Allow-Origin", "http://localhost:3000"); // update to match the domain you will make the request from res.header( "Access-Control-Allow-Headers", "Origin, X-Requested-With, Content-Type, Accept" ); res.header("Access-Control-Allow-Credentials", "true"); next();});