The code below will allow us to change the WordPress login page in a few steps.

Create plugin to change WordPress login form steps

1 – Create a folder and named with your plugin’s name, example( ns-loginform )

2 – Inside your plugin’s folder we need to create another folder and named  “assets”, this folder will keep our css styling.

3 – On your plugin’s folder create a php file with your text editor and add the code below named your-plugin-name.php the name has to match the plugin’s folder name.

Your plugin php file will look like the same below.

 * Plugin Name:       your-name
 * Plugin URI:
 * Description:       Change logo and style wordpress login form  
 * Version:           1.0
 * Author:            Your Name
 * Author URI:
 * Text Domain:


/*** Function Add Custom Login  ****/
function ns_custom_login_logo() {
   echo '<style type="text/css">h1 a { background-image:url( !important; } body{background: #e0e0e0 !important; }</style>';
add_action('login_head', 'ns_custom_login_logo');

function ns_login_logo_url() {
                return get_bloginfo( 'url' );
add_filter( 'login_headerurl', 'ns_login_logo_url' );

function ns_login_logo_url_title() {
                return 'Nuno Sarmento - Freelance WordPress Developer';
add_filter( 'login_headertitle', 'ns_login_logo_url_title' );


Thank you for seeing my tutorial and fell free to share and comment 🙂 . Do you have a code snippet and you want to see it publish on my site ? I will be more than happy to do it please send me a message (here)