title: Node.js & MySQL - Error: 1251 - Client does not support authentication protocol requested by server; consider upgrading MySQL client
body: <p>Right now I have only this code:</p>
  
  <pre><code>const Sequelize = require('sequelize');
  const sequelize = new Sequelize('database', 'root', 'passwd', {
    host: 'localhost',
    dialect: 'mysql',
  
      // http://docs.sequelizejs.com/manual/tutorial/querying.html#operators
    operatorsAliases: false
  });
  sequelize
    .authenticate()
    .then(() =&gt; {
      console.log('Connection has been established successfully.');
    })
    .catch(err =&gt; {
      console.error('Unable to connect to the database:', err);
    });
  </code></pre>
  
  <p>But when I try to run the .js I get <a href="https://i.stack.imgur.com/EFeDd.png" rel="noreferrer">this error</a>. I have already tried a lot of solutions out there, including the one I found <a href="https://i.stack.imgur.com/tZHVi.png" rel="noreferrer">more often but it didn't work</a>. So right now I don't know what to do. Can somebody help me?</p>
  
  <p>Thank you</p>