# Change backgroundcolor in workflow

**URL:** <https://community.weweb.io/t/change-backgroundcolor-in-workflow/18831>\
**Category:** How do I?\
**Created:** [June 19, 2025, 10:51am UTC](https://community.weweb.io/t/change-backgroundcolor-in-workflow/18831 "2025-06-19T10:51:31Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![WimDC](https://avatars.discourse-cdn.com/v4/letter/w/8e7dd6/32.png) [@WimDC](https://community.weweb.io/u/WimDC)\
**Post date:** [June 19, 2025, 10:51am UTC](https://community.weweb.io/t/change-backgroundcolor-in-workflow/18831/1 "2025-06-19T10:51:31Z")

</div>

Hi,

is it possible to change the backgroundcolor of a list-item (or another element) within a workflow?  
I tried with AI, but without result.

(In my project I want to change the backgroundcolor of a list-item when it is clicked)

---

<div class="post-metadata">

**Author:** ![Batik\_Okazov](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/batik_okazov/32/12688_2.png) [@Batik\_Okazov](https://community.weweb.io/u/Batik_Okazov)\
**Post date:** [June 19, 2025, 3:03pm UTC](https://community.weweb.io/t/change-backgroundcolor-in-workflow/18831/2 "2025-06-19T15:03:01Z")

</div>

Hi,

you can bind the “color” property of the “background” section to a variable.

 ![image](https://us1.discourse-cdn.com/flex016/uploads/weweb/original/2X/f/f40481623441970cba9f4a3844af1576b9a4ca45.png)

And by changing the value of that variable within a workflow you can change any color of any element.

---

<div class="post-metadata">

**Author:** ![WimDC](https://avatars.discourse-cdn.com/v4/letter/w/8e7dd6/32.png) [@WimDC](https://community.weweb.io/u/WimDC)\
**Post date:** [June 19, 2025, 3:54pm UTC](https://community.weweb.io/t/change-backgroundcolor-in-workflow/18831/3 "2025-06-19T15:54:43Z")

</div>

Nice solution, never thought to do it this way.  
Thanks !

---

<div class="post-metadata">

**Author:** ![WimDC](https://avatars.discourse-cdn.com/v4/letter/w/8e7dd6/32.png) [@WimDC](https://community.weweb.io/u/WimDC)\
**Post date:** [August 26, 2026, 4:03pm UTC](https://community.weweb.io/t/change-backgroundcolor-in-workflow/18831/4 "2026-08-26T16:03:54Z")

</div>

Hi @Batik_Okazov,

in a new project I am using a formula in the (backgrond-)color property that checks if a certain value exist in a column of my connected Baserow-API. (red if exists, gray if not exists).  
In my case : if the value doesn’t exist when opening that page, the background-color is grey (= Correct), but when I add the value with a workflow (so the value then exists in the Baserow-field), the color stays red in stead of “automatically” changing to red.

Even after a “fetch collection” at the end of the workflow, the field still has the (old - initial) gray background instead of the (expected) red color.

So it seems that the “fetch collection” flow doesn’t activate the formula in the color-parameter.

Any idea how to solve?

I tried with a variable to change the background-color, but then all the items have the new background-color, not the one I wanted.

The first screenshot shows the list of items with the initial red background if name exist in field.  
In the second screenshot there’s the formula for the color-element  
The third screenshot shows part of the workflow where the new name is added to Baserow (GET API - works fine) and the “fetch-collection”-action (that doesn’t give me the updated result)

 ![Schermafdruk van 2026-08-26 17-57-07](https://us1.discourse-cdn.com/flex016/uploads/weweb/original/3X/3/9/396069d2a18b745f0456140b2a139be80d367879.png)  
 ![Schermafdruk van 2026-08-26 17-58-18](https://us1.discourse-cdn.com/flex016/uploads/weweb/original/3X/b/1/b185b9cc4365e9e2dfb6f55fa9935951ef2043c7.png)  
 ![Schermafdruk van 2026-08-26 17-57-35](https://us1.discourse-cdn.com/flex016/uploads/weweb/original/3X/6/0/60431dc397f8542d6e7f8aaaf9ce0cf371156b72.png)

If - after the workflow - I go back to previous screen (navigate in the app) and reopen the detail-screen, I see the correct color for the added name.

So the problem is in the “realtime-update” from Baserow.

---

<div class="post-metadata">

**Author:** ![Batik\_Okazov](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/batik_okazov/32/12688_2.png) [@Batik\_Okazov](https://community.weweb.io/u/Batik_Okazov)\
**Post date:** [August 26, 2026, 4:25pm UTC](https://community.weweb.io/t/change-backgroundcolor-in-workflow/18831/5 "2026-08-26T16:25:18Z")

</div>

Hi Wim,

when you make REST API call to save new data in Baserow are you sure you correctly update your ‘gekozen\_repetitiedatum.OPT\_namen\_NEE’ variable after the ‘fetch collection’?

Because ‘fetch collection’ action updates the ‘repetities’ collection only and does not update your custom ‘gekozen\_repetitiedatum.OPT\_namen\_NEE’ variable.

I assume you have an old data inside the variable and that’s why it doesn’t update reactively, but updates only on page load. Maybe you set your variable only on page load event.

---

<div class="post-metadata">

**Author:** ![WimDC](https://avatars.discourse-cdn.com/v4/letter/w/8e7dd6/32.png) [@WimDC](https://community.weweb.io/u/WimDC)\
**Post date:** [August 26, 2026, 7:17pm UTC](https://community.weweb.io/t/change-backgroundcolor-in-workflow/18831/6 "2026-08-26T19:17:48Z")

</div>

Thanks for the suggestion, but how do I (only) update ‘_gekozen\_repetitiedatum.OPT\_namen\_NEE_’ after the fetch? OPT\_namen\_NEE is not a custom weweb-variable but a field (column) in my Baserow-table ‘_repetities_’ (where I save the changes with a REST API)

26 aug. 2026 18:35:24 Batik\_Okazov \<[notifications@weweb.discoursemail.com](mailto:notifications@weweb.discoursemail.com)\>:

---

<div class="post-metadata">

**Author:** ![Batik\_Okazov](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/batik_okazov/32/12688_2.png) [@Batik\_Okazov](https://community.weweb.io/u/Batik_Okazov)\
**Post date:** [August 27, 2026, 10:20am UTC](https://community.weweb.io/t/change-backgroundcolor-in-workflow/18831/7 "2026-08-27T10:20:55Z")

</div>

“filterByKey” formula needs an array as the first argument. So your _gekozen\_repetitiedatum_ should be a variable with an array inside, otherwise the formula wouldn’t work.

Since the formula works you must be placing your collection data inside _gekozen\_repetitiedatum_ var. You just need to update array inside _gekozen\_repetitiedatum_ right after collection fetch.

Can you confirm or elaborate on what exactly _gekozen\_repetitiedatum_ is if it’s not a variable?

---

<div class="post-metadata">

**Author:** ![WimDC](https://avatars.discourse-cdn.com/v4/letter/w/8e7dd6/32.png) [@WimDC](https://community.weweb.io/u/WimDC)\
**Post date:** [August 28, 2026, 6:48am UTC](https://community.weweb.io/t/change-backgroundcolor-in-workflow/18831/8 "2026-08-28T06:48:21Z")

</div>

Thanks to your tips, I’ve taken a thorough look at both the workflow and the variables.  
In a separate post ([Store array with one object into an object-variable - #5 by WimDC](https://community.weweb.io/t/store-array-with-one-object-into-an-object-variable/21564/5)), I reported the issue with the object variable, and a solution was then found.  
This was only possible thanks to your initial help.

So the problem is now sorted – thank you very much!
