I would like to have one login form (either wp-login.php or custom) that will allow my users to sign in into their respective site.

For instance:

www.example.com/site1/ <-- URL to the sub site

Now I want to have the login form at www.example.com where the user can enter site1 and their password and logs in to their sub site, redirect to their dashboard directly.

Is this possible? Thanks folks.

  • This is how it works already. Are your Mu units separate domains?
    – prosti
    Jan 12, 2017 at 19:22
  • No, I use subdirectory mode on the root domain. Might move to sub-domains in the future.
    – Amjad
    Jan 12, 2017 at 19:26
  • 2
    You can modify the login form using various filters to add your proposed site field. You can filter the destination once the user is logged in using the login_redirect hook. And you can even filter the login URL using the login_url hook. So yes, it looks like it's very possible.
    – Pat J
    Jan 12, 2017 at 19:52
  • 1
    Thanks @PatJ for the nudge in the right direction. Now I hope someone writes in a custom function for this to make it easier.
    – Amjad
    Jan 12, 2017 at 20:19
  • 1
    Thanks. But like @prosti said, it is how it works already. Turned out, I just needed to make sure the user is not added to the main site.
    – Amjad
    Jan 15, 2017 at 7:12

1 Answer 1


Apparently, this is how it works already. You can have the user sign in using the main site's wp-login.php.

In your case just make sure the user is not added to the main site.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.