Title: wp_create_application_password
Published: December 9, 2020
Last modified: May 20, 2026

---

# do_action( ‘wp_create_application_password’, int $user_id, array $new_item, string $new_password, array $args )

## In this article

 * [Parameters](https://developer.wordpress.org/reference/hooks/wp_create_application_password/?output_format=md#parameters)
 * [Source](https://developer.wordpress.org/reference/hooks/wp_create_application_password/?output_format=md#source)
 * [Related](https://developer.wordpress.org/reference/hooks/wp_create_application_password/?output_format=md#related)
 * [Changelog](https://developer.wordpress.org/reference/hooks/wp_create_application_password/?output_format=md#changelog)

[ Back to top](https://developer.wordpress.org/reference/hooks/wp_create_application_password/?output_format=md#wp--skip-link--target)

Fires when an application password is created.

## 󠀁[Parameters](https://developer.wordpress.org/reference/hooks/wp_create_application_password/?output_format=md#parameters)󠁿

 `$user_id`int

The user ID.

`$new_item`array

The details about the created password.

 * `uuid` string
 * The unique identifier for the application password.
 * `app_id` string
 * A UUID provided by the application to uniquely identify it.
 * `name` string
 * The name of the application password.
 * `password` string
 * A one-way hash of the password.
 * `created` int
 * Unix timestamp of when the password was created.
 * `last_used` null
 * Null.
 * `last_ip` null
 * Null.

`$new_password`string

The generated application password in plain text.

`$args`array

Arguments used to create the application password.

 * `name` string
 * The name of the application password.
 * `app_id` string
 * A UUID provided by the application to uniquely identify it.

## 󠀁[Source](https://developer.wordpress.org/reference/hooks/wp_create_application_password/?output_format=md#source)󠁿

    ```php
    do_action( 'wp_create_application_password', $user_id, $new_item, $new_password, $args );
    ```

[View all references](https://developer.wordpress.org/reference/files/wp-includes/class-wp-application-passwords.php/)
[View on Trac](https://core.trac.wordpress.org/browser/tags/7.0/src/wp-includes/class-wp-application-passwords.php#L150)
[View on GitHub](https://github.com/WordPress/wordpress-develop/blob/7.0/src/wp-includes/class-wp-application-passwords.php#L150-L150)

## 󠀁[Related](https://developer.wordpress.org/reference/hooks/wp_create_application_password/?output_format=md#related)󠁿

| Used by | Description | 
| [WP_Application_Passwords::create_new_application_password()](https://developer.wordpress.org/reference/classes/wp_application_passwords/create_new_application_password/)`wp-includes/class-wp-application-passwords.php` |

Creates a new application password.

  |

## 󠀁[Changelog](https://developer.wordpress.org/reference/hooks/wp_create_application_password/?output_format=md#changelog)󠁿

| Version | Description | 
| [6.8.0](https://developer.wordpress.org/reference/since/6.8.0/) | The hashed password value now uses [wp_fast_hash()](https://developer.wordpress.org/reference/functions/wp_fast_hash/) instead of phpass. | 
| [5.6.0](https://developer.wordpress.org/reference/since/5.6.0/) | Introduced. |

## User Contributed Notes

You must [log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fdeveloper.wordpress.org%2Freference%2Fhooks%2Fwp_create_application_password%2F)
before being able to contribute a note or feedback.