Paste the following in functions.php:

function my_login_logo() { ?>
    
        #login h1 a, .login h1 a {
                background-image: url(https://linktologo.com);
		height:65px;
		width:320px;
		background-size: 320px 65px;
		background-repeat: no-repeat;
        	padding-bottom: 30px;
        }
    
<?php }
add_action( 'login_enqueue_scripts', 'my_login_logo' );

Change parameters as needed.

Source: https://codex.wordpress.org/Customizing_the_Login_Form#Styling_Your_Login