I wrote a module where I using a form for editing my module's configs. My current goal to be able to translate some of my config field's values with configuration translation. I already implemented the followings:

  • For the menus:

    • mymodule.links.menu.yml
    • mymodule.links.task.yml
  • For the translation:

    • mymodule.config_translation.yml
    • config/schema/mymodule.schema.yml (I indicated also which should be translated and which shouldn't)

I also added language into my config, however, I don't think there's any meaning for it

My current problem is: when I going to my settings page, I go to the translate tab, add a language and that form is totally empty. There's no field listed where I can write anything, just a save button... what am I missing?


service_id: ''
normalized: true
success: 'Successfully subscribed!'
langcode: en


  type: config_object
  label: 'Mymodule settings'
      type: string
      label: 'Success message'
      translatable: true
      type: boolean
      label: 'E-mail address should be normalized?'
      translatable: false
      type: string
      label: 'Service id'
      translatable: false


  title: 'Mymodule Settings'
  route_name: mymodule.mymodule_settings_form
  description: 'Configure Mymodule integration'
  parent: system.admin_config_system
  weight: 99


  base_route: mymodule.mymodule_settings_form
  title: 'Mymodule Settings'
  route_name: mymodule.mymodule_settings_form


  path: '/admin/config/system/mymodule-settings'
    _form: '\Drupal\mymodule\Form\MymoduleSettingsForm'
    _title: 'Mymodule Settings Form'
    _permission: 'manage mymodule settings'
    _admin_route: TRUE


manage mymodule settings:
  title: 'Manage mymodule settings'
  description: 'Allows users to configure mymodule'


  title: 'Newsroom Mymodule Form'
  base_route_name: mymodule.mymodule_settings_form
    - mymodule.mymodulesettings
  • 1
    What I learned so far from configuration translation is that you need at least one root property to be translatable in order to make nested keys to be translatable.
    – d70rr3s
    Jan 24, 2020 at 14:26
  • 1
    Also worth checking stackoverflow.com/questions/50862690/…. TLDR; hojtsy.hu/blog/2014-may-26/…
    – d70rr3s
    Jan 24, 2020 at 14:28
  • I don't have nested keys, all keys are in the same level and I viewing the site as user 1 Jan 24, 2020 at 14:34
  • 2
    I think I found the problem, on your schema change the type from string to label for those you want to be translatable. Also remove all translatable: false since its the default behavior. Also for label does not need the translatable key since also defualt. Check this hojtsy.hu/files/ConfigSchemaCheatSheet1.5.pdf
    – d70rr3s
    Jan 24, 2020 at 15:55
  • 2
    Yes, the label was the missing part. langcode is not required to schema I think, because the config_object contains it. Jan 24, 2020 at 16:03

1 Answer 1


The problem as commented above is the type of the translatable properties on the schema. Needs to be changed from string to label also the translatable: false can be safely removed since is default behavior, and also no needed for label or text types.

For more information about config translation check the cheatsheet.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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