Search Engine Optimization is an important area to address when implementing and developing an ecommerce solution to ensure competitive search engine performance.
This guide mostly covers using the default Spree frontend based on Ruby on Rails.
If you’re using your own storefront and communicating with Spree over the API
the most important thing will be to properly render
meta_description returned from the Products and Taxons API endpoints.
Chapter 1 contains a description of the work that has been completed to address common search engine optimization issues.
The helper method
seo_url(taxon) yields SEO friendly URLs such as:
Each controller is configured to serve the content using these keyword-relevant, meaningful URLs.
Several enhancements have been made to improve on-page keyword targeting. The admin interface provides the ability to manage meta descriptions and meta keywords at the product level. Additionally, H1 tags are used throughout the site for product and taxonomy names. The ease of extension development and layout changes allows you to target keywords throughout the site.
Taxons also have
meta_description on them. (You can configure these in the Admin > Configuration > Taxonomies). If you want to add keywords and description to another kind of object in Spree, you can do so simply by adding those two fields (
meta_description) onto the object in question. The Spree controller must instantiate an instance variable of the same class name as the controller (so, for example,
@taxon for the TaxonsController) for this to work. Check out the
meta_data method in base_helper.rb for details on how that works.
To integrate with Google Analytics you need to install Analytic Trackers extension.
The following list shows extensions that can improve search engine performance. Refer to the GitHub README for developer notes.