New yaml file is not loading?

Hey,
i created a new yaml file it called wetterstation.yaml it is for my mqtt-weatherstation. I want all the mqtt-messages in a new yaml file for a better overview.

So i added in configuration.yaml a new line:

group: !include groups.yaml
automation: !include automations.yaml
script: !include scripts.yaml
wetterstation: !include wetterstation.yaml

But when i check the configuration, it says: Component not found: wetterstation

Where is the problem?

Thanks and greetings

wetterstation: is not a component of home assistant.

MQTT messages are not stored in yaml files. Component configurations are.

ok thanks, so i create a sensor.yaml and put all the stuff in this

You can use the include directories instead of files. That way you can include a whole bunch of files called whatever you want.

But they will still have to put that include statement inside a known component such as “sensor:”.