User-related tables

This category consists of two tables that contain the user-related information of your application. Let's take a look at the relationship between user-related tables before moving onto the explanation:

The two tables shown in the preceding diagram are as follows:

  • wp_users: All the registered users will be stored in this table with their basic details, such as name, e-mail, username, and password.
  • wp-usermeta: This table is used to store additional information about the users as key-value pairs. User roles and capabilities can be considered as the most important user-specific data of this table. Also, we have the freedom to add any user-related information as new key-value pairs.
Throughout this chapter, we'll be referring to WordPress tables with the default prefix of wp_. You can change the prefix through the installation process or by manually changing the wp-config.php file in the root directory.