VWO Destination Config Reference
Beta- free
- growth
- enterprise
7 minute read
VWO (Visual Website Optimizer) is an A/B testing destination that runs only in web device mode. RudderStack’s JavaScript SDK passes identify traits and track events to VWO in the browser, prefixing each trait and event name with rudder., and can report the variations VWO applies back to RudderStack as events.
In a VWO destination spec:
type: vwodefinition_version: 1
Sample configuration
version: rudder/v1
kind: destination
metadata:
name: vwo-prod
spec:
id: vwo-prod
display_name: VWO Production
type: vwo
definition_version: 1
enabled: true
config:
account_id: "{{ .VWO_ACCOUNT_ID }}"
send_experiment_track: true
send_experiment_identify: true
is_spa: true
library_tolerance: "2500"
settings_tolerance: "2000"
use_existing_jquery: false
event_filtering:
whitelist:
- Order Completed
- Signed Up
connection_mode:
web: device
consent_management:
web:
- provider: oneTrust
consents:
- analyticsThe above example sets the SmartCode keys, which take effect only when the page has the SDK load VWO’s SmartCode — see SmartCode settings.
Config keys
config accepts only the keys listed below. The shared config key rules cover unknown keys, defaults, and immutability.
VWO runs only in web device mode. The SDK forwardsidentifyandtrackcalls to VWO, and also records anOrder Completedevent’stotal— orrevenue, whentotalis absent — as a VWO revenue conversion. See Tracking revenue goals.
Connection
account_id
RequiredSecretType:
string
Description: Your VWO account ID, from Account Details in VWO’s account settings. The SDK uses it when it loads VWO’s SmartCode itself — see SmartCode settings.
Notes:
- Written as a string, so quote its reference:
"{{ .VWO_ACCOUNT_ID }}". Rudder CLI substitutes the value before it parses the YAML, so an unquoted reference to a numeric ID becomes a number and fails validation. - At most 100 characters, and must not contain line breaks.
- A
{{ path || fallback }}template is accepted in place of a literal. - A spec that omits this key fails validation with
'account_id' is required.
Supply it as a {{ .VAR }} reference rather than a literal — see Secrets.
Experiment reporting
These keys have the SDK report each variation VWO applies to a visitor back to RudderStack, so the other destinations connected to the source can analyze experiment results.
send_experiment_identifytakes effect only whensend_experiment_trackis alsotrue— the SDK listens for applied variations only whensend_experiment_trackis on. Set both to get the identify traits.
send_experiment_track
Type:
boolean
Default value:
false
Description:
Send an Experiment Viewed track event whenever VWO applies a variation, with the experiment ID, campaign name, variation ID, and variation name as properties. The dashboard calls it Send experiment viewed as track.
send_experiment_identify
Type:
boolean
Default value:
false
Description:
Send an identify call whenever VWO applies a variation, with a trait named Experiment: <experiment ID> holding the variation name. The dashboard calls it Send experiment viewed as identify traits.
Notes:
- Takes effect only when
send_experiment_trackis alsotrue.
SmartCode settings
These keys configure VWO’s SmartCode snippet. The SDK adds SmartCode to the page — with account_id and these settings — only when the page’s load call opts in through its integration options:
rudderanalytics.load(WRITE_KEY, DATA_PLANE_URL, {
integrations: {
VWO: {
loadIntegration: true
}
}
});Without that option, the SDK expects VWO’s SmartCode to be on the page already, and neither account_id nor the four keys below have any effect. See Loading the VWO SDK.
is_spa
Type:
boolean
Default value:
false
Description: Tell SmartCode the page is a single-page application. The dashboard calls it Single Page Application (SPA)?.
library_tolerance
Type:
string
Description: Maximum time, in milliseconds, SmartCode waits for the VWO library to load before it shows the original page. The dashboard calls it Library Tolerance.
Notes:
- Digits, written as a string:
"2500", not2500. Rudder CLI doesn’t check that the value is a number. - At most 100 characters, and must not contain line breaks.
- A
{{ path || fallback }}template is accepted in place of a literal. - The dashboard defaults this field to
2500. Rudder CLI doesn’t fill it in.
settings_tolerance
Type:
string
Description: Maximum time, in milliseconds, SmartCode waits for campaign settings before it shows the original page. The dashboard calls it Setting Tolerance.
Notes:
- Digits, written as a string:
"2000", not2000. Rudder CLI doesn’t check that the value is a number. - At most 100 characters, and must not contain line breaks.
- A
{{ path || fallback }}template is accepted in place of a literal. - The dashboard defaults this field to
2000. Rudder CLI doesn’t fill it in, and without it SmartCode shows the page without waiting for settings.
use_existing_jquery
Type:
boolean
Default value:
false
Description: Use the jQuery already on the page instead of having VWO add its own. VWO needs jQuery on the page either way. The dashboard calls it Use Existing jquery.
Event filtering
Every source connects to VWO in device mode, where the SDK applies the filter, so the filter applies to track events from every source you connect.
event_filtering
Type:
object
Description:
Restricts which track events the SDK passes to VWO, by event name. See Client-side Events Filtering.
Notes:
whitelist— array of event names to allow; every othertrackevent is dropped.blacklist— array of event names to drop; every othertrackevent is allowed.- The two are mutually exclusive, and Rudder CLI enforces it — setting both fails validation.
- Each name is at most 100 characters, or a
{{ path || fallback }}template.
event_filtering:
whitelist:
- Order CompletedPer-source keys
Both keys are objects keyed by the local source type — the tokens listed under Source types. A key naming a source type this destination doesn’t support fails validation.
connection_mode
Type:
object
Description:
Maps each source type you connect to the mode its events reach VWO in. VWO accepts only web: device.
Notes:
- An entry is required for each source type you connect — see Connect a source.
connection_mode:
web: deviceconsent_management
Type:
object
Description:
Consent provider configuration per source type. The entry shape, accepted providers, and the rules on resolution_strategy and consents are shared across all destination types — see Consent management.
Source types
VWO accepts events from these source types in the mentioned connection modes:
| Source type | Connection mode |
|---|---|
web | device |
VWO accepts only web sources, and only in device mode — the SDK runs VWO in the browser, and no events pass through RudderStack’s servers. See RudderStack Connection Modes.
Connect a source
An event stream connection to this destination is checked against two rules at validate time.
The source’s type must be supported. VWO accepts only web, the type a JavaScript source resolves to. Every other source resolves to a type it doesn’t accept — an iOS source to ios, an Android source to android, and webhook and server-side SDK sources to cloud — and reports, for example:
destination 'vwo-prod' (type 'vwo') does not support source 'my-ios-app':
source type 'ios' is not among supported source types: webThe destination config must carry a connection_mode entry for that source type. This lives on the destination spec, not on the connection spec. Without it:
destination 'vwo-prod' config has no 'connection_mode' entry for source type 'web'VWO needs no additional config keys to connect a web source.
Secrets
account_id is the only secret key. Write it as a {{ .VAR }} reference and supply the value at apply time:
config:
account_id: "{{ .VWO_ACCOUNT_ID }}"export RUDDER_VWO_ACCOUNT_ID="..."
rudder-cli apply
# or
rudder-cli apply --var-file secrets.vars.yamlNote that:
rudder-cli importwrites only the secrets the API returns, as{{ .VAR }}references, and leaves the others out. Add any secret key it leaves out, then supply the variables before you apply — see Secrets.- The account ID is embedded in the page’s JavaScript, so masking it protects your YAML, not the value itself.
See How to Use Variable Substitution in Rudder CLI.
Changes by release
No changes since this type became available.
For changes across every destination type, see Destination Type Changes by Release.
See more
- VWO Destination for loading SmartCode, experiment reporting, and revenue tracking
- Destination Type Reference for Rudder CLI for the rules shared across destination types
- Destination YAML Reference for the spec envelope