Overview
The WP OAuth Server plugin allows for you have a custom login page and still provide OAuth services.
/** * CUSTOM LOGIN REDIRECT * * Redirect a user to a custom login page for authentication */ add_action( 'wo_before_authorize_method', 'custom_login_redirect' ); function custom_login_redirect() { if ( ! is_user_logged_in() ) { wp_redirect( site_url() . '/custom-login?redirect_to=' . urlencode( site_url() . $_SERVER['REQUEST_URI'] ) ); exit; } }
Applying the Custom Login Code
Extending WP OAuth Server can be done via the current themes functions file. Read more about the functionality of a themes function file by visiting https://developer.wordpress.org/themes/basics/theme-functions/.
Place the snippet from above in your functions.php file. You may need to change the parameter for redirect to work with your custom needs.