In WordPress with Meta Widget, users can register and login to your website. Unfortunately, the widget backend has no options to remove your website RSS link; your website comments RSS link and the WordPress.org link.
Editing core file /wp-includes/default-widgets.php
For a login/register widget, all those links are not necessary, and most of the people don’t want these links in their meta widget.
Removing these links from your meta widget is easy and can be accomplished in just a couple of minutes. There is only one file that needs to be edited, default.widgets.php located inside the wp-includes folder.
The path is here: your_website_root/wp-includes/default-widgets.php
Editing your WordPress core file nor recommended, but if you still want to edit, follow these steps. You will lose those changes to the file when you upgrade the WordPress core, so create a backup.
Edit Meta Widget In WordPress
Open the default-widget.php and search for meta until you find the below screenshot lines. Delete the second, third and fourth<li></li>lines.
The final code should look like:
<ul>
<?php wp_register(); ?>
<li><?php wp_loginout(); ?></li>
<?php wp_meta(); ?>
</ul>
Now in your meta widget, you will find only Login & Register links.
There is an update here…
I am using WordPress version 5.4.2.
and the file location and name changes in this version
Location: public_html/wp-includes/widgets
Filename: class-wp-widget-meta.php
Thanks for this easy and recent writeup, and thanks to Keyur’s input to update the location and filename change. I have been looking for steps on removing the entries, comments feeds and wp.org links to save front page space.
There is a better way for this, just by adding some CSS to remove an element:
.widget_meta li:nth-child(5) {
display:none;
}
In this case, that fifth child, is also the last one, so this would also work:
.widget_meta li:last-child {
display:none;
}
No need to change any files.
I added that with a CSS-plugin, and it should still work after a wordpress update.