How to store user meta data?
You can use the user.data service

\Drupal::service('user.data')-&gt;set('mymodule', $uid, 'some_key', 'some_value');


You can then retrieve it with the same service:

$some_key = \Drupal::service('user.data')-&gt;get('mymodule', $uid, 'some_key');