Now in Next 15, remove bcrypt : yarn remove bcrypt install bcryptjs : yarn add bcryptjs in your code : import bcrypt from 'bcryptjs';