What's the difference between optimized and full selectors?

When you click on an element using Inspect Mode, Fullstory provides an optimized selector and a full selector that you might want to use in your search. What's the difference between the two? 

Full Selector

Simply put, the full selector includes the full selector chain and all related attributes for your selected element.

Inspect Mode - Full Selector 362px

Optimized Selector

The optimized selector removes any noisy or dynamic attributes and respects the element attributes configured in your Fullstory settings.

Inspect Mode - Optimized Selector

Numeric characters in optimized selectors

As part of optimizing the selector, please note that numeric characters will be stripped out. If you would like to ensure that a particular value is not stripped out, an account Admin or Architect can modify the id and class attributes from the Settings > Data Management > Indexed Element Attributes page to configure a pattern rule. You may wish to use a wildcard * to ensure that all attribute values are passed through into the optimized selector. Once a new attribute has been configured, indexing will apply to future sessions.

To learn more about setting up element-specific rules, see Using Indexed Element Attributes in Search & Page Analytics.

Which should I use?

Generally, using the optimized selector will help you run a more effective search; however, the exact version of the selector you choose will ultimately depend on your specific use case and site configuration.

Several attributes are added to the allowlist by default. You can view the full list of those attributes here. For any other attributes you'd like to index in your Fullstory account, an Admin or Architect user will need to allowlist them on the Settings > Data Management > Indexed Element Attributes page. Once added, these attributes will be indexed in new sessions moving forward as this setting would not apply retroactively.

 


Was this article helpful?

Got Questions?

Get in touch with a Fullstory rep, ask the community or check out our developer documentation.