Remove the WordPress Version Number to Get Rid of the Backend Upgrade Notification
Every time WordPress releases a major version update, the backend always displays a prominent update notification box. Moreover, this notification cannot be closed, making it quite distracting. To remove this update notification, I researched a method that involves modifying the version number. It is very simple and practical. Next, I will explain in detail how to remove the WordPress update notification and modify the version number.
Specific Steps
Method 1: Remove the Update Notification by Modifying the Version Number
- Open the file
/wp-includes/version.php. - Find the
$wp_versionvariable. - Change the value of
$wp_versionto a higher version number, for example:
Original code:After modification:PHP PHP$wp_version = '4.7.0';PHP PHP$wp_version = '5.0.0';
In this way, you not only modify the version number but also successfully suppress the update notification in the WordPress backend, achieving two goals at once.
Notes:
Although this method is simple, it is not recommended for long-term use. In particular, when official important security patches are released, be sure to update WordPress promptly to avoid being attacked by hackers due to vulnerabilities.
Method 2: Remove Only the Backend Update Notification Without Modifying the Version Number
If you want to retain the current version number while hiding the annoying update notification box in the backend, you can do so through the following steps:
- Open the file
wp-admin/includes/update.php. - Find the following code:
PHP PHP
echo "<div id='update-nag'>$msg</div>"; - Delete or comment out this line of code.
After saving the changes, the update notification will no longer be displayed, while the version number will remain unchanged.
Recommendations
Although hiding update notifications can make the backend look cleaner, WordPress updates often involve security fixes, especially patches for major vulnerabilities. Therefore, it is recommended to regularly check the official WordPress update information and upgrade the version promptly to ensure the security of your website.

Comments
(0)No comments yet. Start the conversation.