Clean messy text in Make with trim and lower
Trim off any extra spaces before/after a label and normalize the capitalization in Make Free. Set up a two-module practice workflow. Examine the results. What does not change with trim?

Sometimes you may copy a form into a product label and find that it has extra spaces or odd capitalizations. With Make, you can use the trim and lower functions (opens in a new tab) to ensure your label is standardized before going to your next workflow step.
Before you start
This is an example using the dummy text and two of the built-in Tools modules in Make Free. It's manual and doesn't write anything to another app. You will need to have a Make account for this. Get your free Make account here (opens in a new tab) If you already have a Make account, log in and continue below.
1. Create a label to clean
- Navigate to Scenarios > Create scenario > Text cleanup practice
- Go to Tools > Set variable > Variable name: raw_label.
- Enter the following line in Variable value. Each space expression should be turned into coloured tokens. You should have 2 tokens in front and 2 tokens behind BLUE NOTEBOOK.
- In the module, Save. Don't activate the scenario
{{space}}{{space}}BLUE NOTEBOOK{{space}}{{space}}
The tokens provide leading and trailing two spaces. They ensure that the example is repeatable. That's because the editor can trim spaces that are added by typing them at the ends of plain text value.
2. Apply trim, then lower
There is a first Tools module. If you click on the plus next to it, a second Tools > Set variable module will appear.
In the second module, set Variable name to clean_label and in the Variable value use the following formula.
The coloured raw_label token, is for the value of the first module.
The inside is the trim function for the value. And the lower function for the trim.
Save the second module by pressing the Save button on the second module.
Then use the bottom Save button to save the scenario.
{{lower(trim(1.raw_label))}}
In this case 1 is the ID of the first module. If your ID is different then you need to pick the raw_label value of it in the mapping panel. Check Make's function instructions (opens in a new tab) to learn how to add the functions and mapped values.
Watch out
trim will just cut off space from the ends. It won't touch spaces between words. lower will make everything lowercase, so only use that if you want everything in lowercase. You want to keep the original if there's something about the spelling or capitalization you care about.
3. Run once and read the result
- click run once; let it run to completion
- click on the small operation bubble above the second Tools module
- view Output. You'll see clean_label = blue notebook
For this exercise each Tools module consumed 1 credit (2 credits per run). You get 1000 credits a month for free. I recommend looking at current Make plan limits (opens in a new tab) before you plan a big workflow.
4. Check what stays unchanged
- Now in the 1st module, change the Variable value to this. It will also insert 2 spaces between words.
- Next, click on the Save button in that module and Run once. Now check again the Output on the 2nd module.
When you click on "Save" in the 1st module, "Run once" means that the entire 2-module scenario will be run. The new output that you need to check is the output from the 2nd module.
{{space}}{{space}}BLUE{{space}}{{space}}NOTEBOOK{{space}}{{space}}
So it comes out lowercase still with two spaces between blue and notebook. trim doesn't compress that.
Try just entering {{space}}{{space}} as the first value. After cleaning, you'll get nothing. Make will show it as empty. Figure out what to do with an empty label in your actual use-case before handing it off.
As a double-check, simply enter only {{space}}{{space}} as the first value. After cleaning, you get nothing. Make will show that value as empty. Determine what to do with an empty label in your actual use-case before you hand it off.
If the result looks wrong
- If the result includes your formula, go back to the second module. Make sure you have functions and raw_label as tokens, not as a text.
- If you don't have raw_label make sure your modules are linked in the right order and you've remembered the first module variable name.
- If the result is empty then look at the output from your first module. If the input is only spaces then it will be empty after trimming.
Remember to put the original label back and save when you're done. Keep this practice scenario Inactive. When doing real work you should always map the cleaned value to the next module only after you've verified. You should use a filter if you need to block unwanted records.
If you'd like to test trimming and lowercasing for your imaginary label then get started with Make Free (opens in a new tab). Test with just spaces and the regular result. Remember to keep this practice scenario Inactive.
Sources: Text and binary functions (opens in a new tab), Use functions (opens in a new tab), Scenario variables (opens in a new tab), Make pricing (opens in a new tab).
Share this post
From holdmytwist.com/blog/make-clean-text-trim-lower/


