Topics are the addressing system of publish-subscribe protocols. In MQTT they are UTF-8 strings with levels separated by slashes, and subscribers can use wildcards: + matches one level and # matches everything below, so site1/+/temperature collects temperature from every line and site1/# collects all data from the site. Topics are not created in advance; the broker routes on whatever string arrives.
Designing the hierarchy is one of the most consequential decisions in an IoT system, because it decides what can be subscribed to efficiently, how access control is expressed and how easily new devices fit in. A common pattern starts with a stable identifier such as tenant or site and ends with the measurement name. Specifications such as Sparkplug exist precisely to standardize this layout for industrial deployments. MQTT explained has worked examples.
Part of the IoT Glossary. Spotted an error or a missing term? Tell us.