Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

birdietorerik's avatar

Save username and password on my mobile app

Hi!

Have created a webapp in laravel & vue.js When i login to my app on MAC or PC ist remeber my username and password. But if i login to my application with mobile app, it dosent remember my username and password.

Is there a way to get this working on my mobile app ?

0 likes
12 replies
Snapey's avatar

You mean they are auto filled into the login fields? Do you have a password manager on your Mac / PC ? maybe part of the browser you are using?

Either way, its not a Laravel issue.

1 like
birdietorerik's avatar

@Snapey i can save my login info (browser) Next time i login, i dont have to enter password and username. It is standard i think

martinbean's avatar

@birdietorerik What do you mean by mobile app? Do you mean in a mobile browser? Or an actual, native mobile app?

1 like
martinbean's avatar

@birdietorerik Well then it depends on how the native app has been developed. Like web apps, you can add “hints” to inputs to designate what type of data they’re receiving. Various apps on iOS offer to save email and passwords to my Apple Keychain for me when I log in.

1 like
martinbean's avatar

@birdietorerik You don’t create mobile app with Laravel. Laravel is a web framework, and runs on a web server. Mobile apps run on the mobile device itself.

1 like
KenBarlow's avatar

Best practice wouldn't be to store the username and password on a mobile device.

Make use of Laravels Sanctum and Fortify packages for SPA and mobile authentication.

First, authenticate using username and password then issue an API token to the device and store details about the device such as device name etc. Great for allowing the user to log in to your web app at a later date to see currently issued tokens and device names etc.

See documentation: https://laravel.com/docs/9.x/sanctum#mobile-application-authentication

2 likes

Please or to participate in this conversation.