- Published on
How to check the Next.js version in your current project
- Authors
- Name
- hwahyeon
package.json
file:
1. Check the Open the package.json
file and look for the Next.js version under the dependencies
section. You can also use the following command in the terminal to view the contents of the package.json
file.
cat package.json
Example:
{
"dependencies": {
"next": "^12.0.7",
"react": "^17.0.2",
"react-dom": "^17.0.2"
}
}
npm list
command:
2. Use the Run the following command in the terminal to check the installed Next.js version.
npm list next
If you're using yarn, use this command instead:
yarn list next
This will display the Next.js version currently used in your project.