# Change the Fortify login field

> Fortify's username config key is the input name. The Vue login form has to post that same name.

- URL: https://laravel-vuejs.space/fortify-login-username-vue
- Author: Anass Ez-zouaine (https://laravel-vuejs.space/author/anass-ez-zouaine)
- Published: 2026-10-11
- Topics: Laravel, VueJs

People searching “Fortify login username” rename the database column and leave the form posting `email`. Fortify reads the key in `config/fortify.php`.

> **TL;DR**
>
> -   Fortify’s username config key is the input name.
> -   The Vue login form has to post that same name.
> -   Do not accept either email or username unless you wrote a custom user provider.
>
> **Who it's for:** Laravel + Vue developers
>
> **Applies to:** Laravel 13 · Vue 3

## The fix

```php
'username' => 'email',
```

Change that to the column you actually look up, then match the Vue input:

```vue
<input v-model="form.email" name="email" type="email" autocomplete="username" />
```

If the config says `username`, the input `name` and the `useForm` key are `username`. The validation error comes back on that same key. The [Fortify guide](https://laravel-vuejs.space/laravel-fortify-vue) shows the POST to `/login` after the CSRF cookie, for a separate SPA. An Inertia kit posts `/login` on the same origin and does not need that cookie call.

## What to avoid

> **Gotcha**
>
> Do not accept either email or username unless you wrote a custom user provider. Changing the label on the page does not change the column Fortify queries.

## FAQ

**Q: How do I change the Fortify login field?**

Fortify's username config key is the input name. The Vue login form has to post that same name.

**Q: What goes wrong with Fortify login username?**

Many developers rename the database column and leave the form posting `email`. Do not accept either email or username unless you wrote a custom user provider.
