I have a membership site that is using WordPress' inbuilt user registration to manage the users, their roles, and restricted content. I am now developing a mobile app for the members and would like to be able to use the same logins, passwords specifically, across the board. Is this possible directly from Wordpress or the database?

Or should I use something completely different to manage users login details that could be easily pulled into a mobile app?

3 Answers 3


In a nutshell, if a client (in the technical sense) has valid username and password then it can provide it to the WP installation to be checked and be placed in a "privileged" context for all the code to run.

Being web app, native WP authentication is mostly browser/cookie centric. So for a mobile app it highly depends on specific app architecture. It can range from merely very same site loaded in the app shell to using REST API (WP's native or even completely custom).

It should be noted that even using the password for log in your app should likely not store it persistently for security reasons. This is commonly implemented via receiving an access token upon successful authentication.

Overall you should first do research on what technologies you will be using in your mobile app, which authentication approaches they favor, and only then how to best interface it with WordPress.


Yes they can. Its simple. If a user is logged in then within the same browser session the ajax then you can just ask the wp api if the user is logged in from anywhere when used with the nopriv or public api interface of wordpress like so https://gist.github.com/fazlurr/9f9c7cac603e026bd03b


If I recall well


There are several options for authenticating with the API. The basic choice boils down to:

Are you a plugin/theme running on the site? Use cookie authentication Are you a desktop/web/mobile client accessing the site externally? Use OAuth authentication, application passwords, or basic authentication.

The only problem with oAuth is you need to use 1.0 standard. oAuth 2.0 is easier to implement, but the decision was we are not ready since most of the websites don't use HTTP/2

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.