W3cubDocs

/WordPress

do_action( 'user_register', int $user_id )

Fires immediately after a new user is registered.

Parameters

$user_id

(int) User ID.

More Information

This action hook allows you to access data for a new user immediately after they are added to the database. The user id is passed to hook as an argument.

Not all user meta data has been stored in the database when this action is triggered. For example, nickname is in the database but first_name and last_name are not (as of 3.9.1). The password has already been encrypted when this action is triggered.

Typically, this hook is used for saving additional user meta passed by custom registration forms.

Source

File: wp-includes/user.php

View on Trac

Changelog

Version Description
1.5.0 Introduced.

© 2003–2019 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/hooks/user_register