diff --git a/mothermayi.module b/mothermayi.module
index 34ce049..5c267da 100644
--- a/mothermayi.module
+++ b/mothermayi.module
@@ -1,5 +1,6 @@
 <?php
 
+use Drupal\Core\Cache\Cache;
 use Drupal\Core\Form\FormStateInterface;
 
 /**
@@ -24,6 +25,7 @@ define('MOTHERMAYI_ADMINISTER_PASSWORD', 'Administer mothermayi password');
  *   Name of form.
  */
 function mothermayi_form_user_register_form_alter(&$form, FormStateInterface $form_state, $form_id) {
+  
   $user = \Drupal::currentUser();
   // the following doesn't seem to work
   //  $form_state->disableCache();
@@ -34,6 +36,9 @@ function mothermayi_form_user_register_form_alter(&$form, FormStateInterface $fo
   }
   $myconfig = \Drupal::config('mothermayi.settings');
   
+  // Set cache tags so the form is updated when settings are updated.
+  $form['#cache']['tags'] =  Cache::mergeTags($form['#cache']['tags'], $myconfig->getCacheTags());
+  
   $fs = array();
   $pw = $myconfig->get('mothermayi_secret_word');
   if (!empty($pw)) {
