Working with Custom Fields in Windsor.ai

Here’s your ultimate guide to creating custom fields in Windsor.ai.
With this feature, you can effortlessly build new metrics and dimensions, such as CPA, ROAS, or any other key performance indicators, by combining and transforming existing fields from your connected data sources.
If you’re familiar with spreadsheets or BI tools like Looker Studio, you’ll find this process intuitive and quick to implement.
What are custom fields?
Custom fields let you create your own metrics and dimensions using standardized formulas. You can think of it like creating a calculated field in Google Sheets, Looker Studio, or Power BI. For example, if you take “cost” and “conversions” fields from your ad platform, you can easily create a new metric called “CPA” by dividing cost by conversions.
How to create a custom field in Windsor.ai
1. Navigate to the custom fields section: Go to onboard.windsor.ai and head to the data preview.
2. Choose the connector: Select the data source you’re working with. For example, if you’re pulling data from Facebook Organic, pick “Facebook”.
3. Click on the plus button below the available fields:
4. Enter a name for your new metric or dimension and create a formula:
In the formula box, use the fields and functions to define your new metric.
Sample:
sum(float(spend))/sum(float(unique_clicks))
- Refer to fields directly by their name. If you are unsure about the field ID, you can find it by clicking ▼ next to the connector URL in the data preview.
Alternatively, you can also click on the ⓘ button next to the fields in the field search. - Use operators like
+
,-
,*
,/
for arithmetic. - Apply built-in functions such as
sum()
,to_float()
, orreplace()
If needed.Basic syntax:
- Refer to fields directly by their name. If you are unsure about the field ID, you can find it by clicking ▼ next to the connector URL in the data preview.
Examples:
1) CPA formula: To calculate CPA (Cost per Acquisition), you should use the relevant cost
and conversions
metrics. With Windsor.ai available fields, your formula can be:
float(spend) / float(actions_purchase)
Make sure to check the field names from the data fields reference page. They might be named slightly differently depending on the connector (e.g., “spend” or “ad_cost” instead of “cost”).
float(action_values_purchase) / float(spend)
5. Save your custom field: Once you’re happy with the formula, click on Save. The custom field will now be available in the sidebar with all fields alongside other metrics and dimensions. If you want to modify your formula, you can click on the pencil button next to it. To delete, use the trash button.
Video walkthrough
Example 1:
The formula for the campaign grouping field is:
if(
'Japan' in campaign or 'APAC' in campaign, 'APAC',
if('UK' in campaign or 'FR' in campaign, 'EUROPE', 'other')
)
Example 2:
The formula for the clicks2 field is:
float(link_clicks)
Facebook Ads
The formula for the clicks2 field is:
float(clicks)
Google Ads