Change WordPress login logo URL, and title

Change WordPress login logo URL, and title

Change WordPress login logo URL, and title

Want to change WordPress login logo, URL, and title without using any WordPress plugin. Here I shared some useful snippets that will be used to change the default login logo URL and title. So let start to change login page logo WordPress.

The WP snippet changes the logo that is displayed at yourwebsite[.]com/wp-login.php and yourwebsite[.]com/wp-admin

Change WordPress login logo

Change WordPress login logo

Add the below snippets to your theme's functions.php file to Change the default WordPress login logo URL to custom URL and custom title.

function custom_login_logo() {
	echo '<style type="text/css">h1 a { background: url('.get_bloginfo('template_directory').' 50% 50% no-repeat !important; }</style>';
add_action('login_head', 'custom_login_logo');

Change WordPress login URL

Below snippet allows you to customize the URL that is attached to your login logo. Rather than link to, the logo will now link to your website home page.

function change_wp_login_url() {
	return bloginfo('url');
add_filter('login_headerurl', 'change_wp_login_url');

Change WordPress login Page Title

This snippet will be used to change the title attribute of your login logo to the website title defined in your settings area.

function change_wp_login_title() {
	return get_option('blogname');
add_filter('login_headertitle', 'change_wp_login_title');

All of the above functions should be added to your theme functions.php file.


leave a comment
Please post your comments here.

Search Free SEO Tools

Download SEO Tools Android App