# Create sub-topics?

**URL:** <https://meta.discourse.org/t/create-sub-topics/161946>\
**Category:** Development\
**Created:** [August 24, 2020, 9:28pm UTC](https://meta.discourse.org/t/create-sub-topics/161946 "2020-08-24T21:28:47Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![JQ331](https://avatars.discourse-cdn.com/v4/letter/j/41988e/32.png) [@JQ331](https://meta.discourse.org/u/JQ331)\
**Post date:** [August 24, 2020, 9:28pm UTC](https://meta.discourse.org/t/create-sub-topics/161946/1 "2020-08-24T21:28:47Z")

</div>

I would like to make some topics sub-topics of others.

Say I have “Topic A”. On the Topic A page, I will put a button to “create sub topic”. That will allow the user to create a new topic, “topic b”. topic b would be a child of Topic A.

What this means, from the user experience, is:

I could also have a button on the Topic A page to “view all the child topics of Topic A”, and this would go to a list of Topic A’s child topics, such as topic b and any other topics that are children of Topic A.

What’s the best way to do this? (I’m assuming I’ll have to do it in a plugin, which is fine.)

Note I’d only be looking for one level of subtopic down, not [several](https://meta.discourse.org/t/how-do-i-create-a-sub-topic-and-a-sub-sub-topic/127529/11).

Here’s some detail on the possibilities I think could do it:

> **Categories (though this probably is not the best way to go)**
>
> Categories would provide similar functionality to what I have in mind, but that could get too heavy once there are a decent number of topics with subtopics (it seems like overkill to basically have a new category for each parent topic).

or

> **Tags**
>
> The best I can think of right now is using tagging. So that when you click “create sub topic” on Topic A, it opens up a new topic, and I programmatically add a hidden tag, like “Topic-A”, that links to Topic A. Then when you click “view all sub topics” of Topic A, it does a search for the tag “Topic-A”.
> 
> This seems pretty clean, other than the fact that there will be a lot of tags (basically one tag for each main topic, which could end up being a lot).

or

> **Custom Fields for Topics**
>
> Another possibility I’ve considered is to create a custom field for topics, which would be an array of the ids of that topic’s sub-topics. This also could work, but would probably be slightly more complicated to code.
> 
> For example, I’d have to update the main topic’s custom field only after a subtopic is created; and, I’d have to create a new kind of search–searching for all the topics within the main topic’s custom field array–instead of just using the pre-built tag search functionality.

Is there another solution I’m missing?

---

_[View the full topic](https://meta.discourse.org/t/create-sub-topics/161946)._
