# Subflows do not allow for context variables to be used when setting properties. Why?

**URL:** <https://discourse.nodered.org/t/subflows-do-not-allow-for-context-variables-to-be-used-when-setting-properties-why/97902>\
**Category:** Developing Nodes\
**Tags:** subflow\
**Created:** [1 July 2025 17:56 UTC](https://discourse.nodered.org/t/subflows-do-not-allow-for-context-variables-to-be-used-when-setting-properties-why/97902 "2025-07-01T17:56:11Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![Mecworks](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/mecworks/32/101359_2.png) [@Mecworks](https://discourse.nodered.org/u/Mecworks)\
**Post date:** [1 July 2025 17:56 UTC](https://discourse.nodered.org/t/subflows-do-not-allow-for-context-variables-to-be-used-when-setting-properties-why/97902/1 "2025-07-01T17:56:11Z")

</div>

When creating a subflow and editing the properties, you can configure the type of input it can have. The choices are Input, credential, select, checkbox and spinner config node. So, I select Input as the type.

 ![Subflow Properties](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/a/3/a36ff44cb55784e6b87b6d43c05c214fbba782c3.jpeg)

However, when using the subflow, I want to populate the value using a context variable, the choices for input are only string, number, boolean, JSON, buffer and envi\_variable.

 ![Setting Subflow Properties](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/8/7/8785a64bc85579a83ba29b5cd57e38bf47a32434.jpeg)  
Why are context (flow and global) available as choices? What this means is that I need to go through the extra step of placing a change node before calling this subflow, just to retreive the global or flow value and set an environment variable. I should be able to just be able to use the glowbal or flow values directly. Am I missing something?

Ideally, when using a subflow, you should be able to use context values and jsonata expressions in addition to the other input types.

Is there a way to do this? Am I just missing something?

---

_[View the full topic](https://discourse.nodered.org/t/subflows-do-not-allow-for-context-variables-to-be-used-when-setting-properties-why/97902)._
