Categorical attributes
Categorical attributes represent discrete values that products can be grouped by, such as brand, color, material, or product type. The engine uses this classification to optimize faceted navigation and to understand when customers are filtering by category versus searching for specific terms.Feature attributes
Feature attributes describe product characteristics that customers might search for or filter by, such as size, weight, or technical specifications. The engine treats these differently from categorical attributes, applying appropriate matching logic for feature-based queries.Price attributes
Price attributes are specifically designated for monetary values. This classification enables the engine to apply price-specific optimizations, including range-based filtering, price sensitivity detection in user intent processing, and appropriate sorting behaviors for price-related queries.Identifier attributes
Identifier attributes hold codes that shoppers type verbatim to find one exact product. Examples include manufacturer part numbers (MPNs), model or style numbers, and UPC or EAN codes stored in metafields. When a query looks like a product code, Layers switches to SKU prefix detection. Layers always matches the query against variant SKUs and barcodes. It also matches every attribute with the identifier class, at both product and variant level. Use this class when your shoppers search by codes that aren’t in the SKU or barcode fields. Identifier matching works as follows:- Exact and prefix matches. A query matches values that equal it or start with it.
- Formatting is ignored. Matching ignores case, spaces, hyphens, slashes, and periods, so
ABC-123matchesabc 123. - Minimum length. A query needs at least three characters after formatting is removed.
- Single values only. Only text and number values match. List and JSON object values are skipped.
- Published products only. Products that aren’t searchable in Layers don’t match.
Requirements
- Only product metafield (
metafields.*) and variant metafield (variant_metafields.*) attributes can use the identifier class. - An identifier attribute can’t also be searchable. Layers never embeds or keyword-searches identifier values. Turn off Searchable before you assign the class.
- A store can have up to five identifier attributes. SKU and barcode are always matched and don’t count toward this limit.
Automatic identifier detection
Layers can assign the identifier class for you. While Layers reviews metafields for search, it flags fields whose values look like product codes. Once enough distinct products flag the same metafield, Layers adds the identifier class to that attribute. Automatic detection follows the same requirements as manual assignment. It skips attributes that are searchable and stores that already have five identifier attributes. It never overrides a class you set or removed yourself.Assigning the correct class to your attributes helps the search engine deliver more relevant results by understanding the semantic meaning of each attribute in your catalog.
Next steps
- Catalog attributes — Codes, metafield creation, and nested key support
- Attribute options — Searchable, filterable, sortable, and visibility settings
- Computed attributes - Creating dynamic attribute values with Functions
- User intent processing — How the engine interprets search queries