2

Is it possible to display the site UUID on a Drupal 8 module?

3

"display" is pretty ambiguous, but you can get the site UUID like so:

$uuid = \Drupal::config('system.site')->get('uuid');

(depending on context, injecting the config.factory service would be preferable)

It's a string so rendering it will be easy.

|improve this answer|||||
1

for you Drupal 8 site

drush config-get "system.site" uuid

or if you need to change it

drush config-get "system.site" uuid "number you want"
|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.