Magento 2 lets store admins optimize the customer search queries by composing lists of search terms and synonyms. While it is possible to manage this data type in your backend manually, Magento 2 prevents importing or exporting it. This limitation negatively impacts the productivity of your backend administrators since they cannot update Magento 2 search terms and synonyms within a few clicks. However, there is a tool that unlocks the missing ability. Meet the Improved Import & Export extension. This module empowers you to import and export search terms and synonyms in Magento 2

In this article, we describe Magento 2 search terms and synonyms as well as teach you how to manage them. Both search terms settings and search synonyms settings are described below. Besides, you will learn how to import lists of search synonyms and terms to your Magento 2, and how to export those for editing purposes. We shed light on how import and export works and what search terms and synonyms attributes are used.

Table of contents

Introduction

So, what do search terms and search synonyms in Magento 2 do? 

  • Search Terms allow the store administrator to redirect customers to a particular page of the store is a certain search query is entered in the search field.
  • Search Synonyms allow the store administrator to compose a list of queries, separated by commas, that should bear the same search results.

Below you will find the instructions how can one locate these settings in Magento 2 and how to import and export both Search Terms and Search Synonyms to and from Magento 2 store.

Finding and managing Search Terms and Synonyms

Navigate to your Magento 2 administrator panel and proceed to Marketing > SEO & Search. In this menu section you can find both Search Terms and Search Synonyms.

Both sections represent a grid with terms and synonym rules. The grids share native Magento 2 grid look and functionality, and come with filters and mass actions, – nothing special. The differences come when you are creating terms and synonym lists.

Search terms settings

The search terms define the behavior of Magento 2 search when the customer enters a particular search query.

  • Search query – defines a word or a phrase a customer should enter in the search field to get redirected to a particular page.
  • Store – defines the store(s) view the search term is applied to.
  • Redirect URL – defines the URL the customer should be redirected to.
  • Display in Suggested Terms – defines whether the term should be displayed in the Suggested Terms at the Magento 2 front.

Search synonyms settings

The search synonyms allow the store administrator to specify a list a words that should bear the same meaning in terms of providing search results for the customers.

  • Scope – defines the websites to which this particular list of synonyms should be applied.
  • Synonyms – a text field where you specify the words that should bear the same meaning in terms of search. Separate these words by a comma without spaces.

Importing and exporting search terms and search synonyms

Native Magento 2 import and export tool doesn’t let you handle search terms and synonyms, it is only limited to products and customers. To import and export terms and synonyms you will need to use a third party tool. Firebear Studio Improved Import & Export extension version 3.1.8 for Magento 2 allows you to import and export ALL Magento 2 entities including search terms and synonyms.

Get Improved Import & Export extension for Magento 2

Improved Import & Export Magento 2 extension is a full-features data management tool fully operational from Magento 2 administrator panel. Your store administrators without programming knowledge can use it no problem with the explicit documentation that Firebear Studio provides.

The extension features:

  • Support of all Magento 2 entities, including B2B and MSI extensions.
  • Support of all Magento 2 product types: simple, configurable, bundle, grouped, downloadable, virtual.
  • Support of multiple import sources including Google Sheets, FTP/SFTP, Dropbox.
  • Support of REST and SOAP APIs for connection with any system or service.
  • Support of CSV, XML, Excel XLSX, ODS, and Json files.
  • Custom import logic with support of XSLT translation templates.
  • Powerful attribute and separator mapping.
  • Open code and customization endpoints for better integration.
  • One time payment. No SAAS, no recurring payments, no subscriptions

Visit the extension product page for more information.

How import and export works

With Improved Import and Export extension for Magento 2 you will be using jobs. The jobs are a set of rules which define which entity and on what conditions should be import/exported to Magento 2.

To find the extension’s jobs proceed to System > Improved Import/Export > Import Jobs. Here you will be presented with the import jobs grid, from which you can create new import jobs and manage existing ones.

To create new import or export job click ‘Add New Job’ button. In the general job settings specify the name of the job and schedule, if you want the job to be recurring and execute it automatically.

In the Import Settings select the entity you want to import or export. In our case we are interested in Search Terms and Search Synonyms. When the entity and selected and the behavior specified you can proceed to selecting the import source and the file type you will be using.

In the Import Source section you can select the type of the file you will be importing. Improved Import & Export supports CSV, XML, Json, XLSX, and ODS file formats. And specify the source of the file, including: local file, direct URL, Dropbox, FTP/SFTP, and Google Sheets (you only need to share, and paste the link).

Sample files containing all search term and synonym attributes can be found at:

  • Google Sheet Master table – a table where we have gathered all Magento 2 entities and explained every entity attribute.
  • Firebear GitHub – here you can find files of different file types containing sample values for every Magento 2 entity.

Once you have specified the file location hit ‘Validate file’ button. Improved Import & Export extension will run the necessary checks and you will be able to hit ‘Save & Run’ button to execute the entity import.

For more information on how to use Improved Import and Export extension read the extension manual.

Search terms attributes

As every Magento 2 entity search terms and synonyms are composed of a set of attributes, which are stored in the tables. In the table below you can find the description of every attribute and sample values you can use for editing.

Attribute name Reference Values Value example
query_id ID of the search query term. From the administrator panel can be found at the URL of the edit term page For example in the url of the page:

/index.php/admin/search/term/edit/id/2/

ID of the search term is ‘2’.

Can only contain numerals.

132
query_text Search Query – the word or a phrase that you enter in the search query field. Can be any value import
num_results Number of results field of the search term Can only contain numerals 0
popularity Number of Uses field of the search term Can only contain numerals 1
redirect Redirect URL field of the search term. Defines the page where customer should be redirected Must contain a full URL of the page. Including https:// https://firebearstudio.com/
store_id ID of the store the search term is available at Can only contain numerals. The store id can be found at Stores > All Stores section of administrator panel 1
display_in_terms Display in Suggested Terms setting of the search term 1 – Yes

0 – No

1
is_active Defines if the search term is active or disabled 1 – Active

0 – Disabled

1
updated_at The date the search term has been last updated on Can only contain date and time format, for example:

2019-02-13 6:19:21

2019-02-13 6:19:21

Search synonyms attributes

As every Magento 2 entity search terms and synonyms are composed of a set of attributes, which are stored in the tables. In the table below you can find the description of every attribute and sample values you can use for editing.

Attribute name Reference Values Value example
group_id ID of the search synonyms group. From the administrator panel can be found at the URL of the edit synonym group page. For example in the url of the page:

/index.php/admin/search/synonyms/edit/group_id/1/

ID of the synonyms group is ‘1’.

Can only contain numerals.

1
synonyms Synonyms field where you specify the words separated by comma which bear the same meaning in terms of the search Do not put spaces after the commas.

Can contain any symbols.

firebear,studio,fire,bear,studio
store_id ID of the store the synonym group should be applied to Can only contain numerals. The store id can be found at Stores > All Stores section of administrator panel 0
website_id ID of the website the synonym group should be applied to Can only contain numerals. The website id can be found at Stores > All Stores section of administrator panel 0

IMPORTANT: make sure NOT to use THE SAME word for different synonym groups to avoid any errors.

That’s it. Having all the information above you can start importing and exporting Magento 2 search terms and synonyms.

Buy Improved Import and Export extension for Magento 2

If you are interested in importing other entities to your Magento 2 store – refer to the following blog posts:

Magento 2 Search Terms & Synonyms Import & Export FAQ

Let’s take a look at other nuances of importing and exporting search terms and synonyms in Magento 2 with the help of the Improved Import & Export Magento 2 extension.

How to import and export search terms and synonyms to Magento 2 automatically?

If you need to move search terms and synonyms between Magento 2 and third-parties or other Magento 2 websites on a regular basis, you can use the Improved Import & Export extension. It utilizes a cron scheduler to automate data transfers. Thus, you can import and export search terms and synonyms between Magento 2 and external destinations automatically, according to a schedule of updates. Next, the module does everything for you.

How to import search terms and synonyms with third-party attributes to Magento 2?

Magento 2 blocks the import of third-party data that doesn’t follow its requirements. However, you can enable the missing opportunity to work with external attributes with the help of the Improved Import & Export extension. The module lets you create a mapping scheme where you match third-party attributes and values to ones used within the system. As a result, any external data, including search terms and synonyms, is easily adapted to the native standards of your e-commerce website. Note that you can also apply mapping to export processes to generate the output your partners require.

How to import and export search terms and synonyms to Magento 2 via API?

The Improved Import & Export Magento 2 extension provides the ability to create API connections for transferring search terms and synonyms along with other entities. There is a dedicated section module’s import/export jobs where you specify parameters necessary to sync the two systems. Note that you can create a bi-directional API connection for transferring search terms and synonyms. As for unsupported attributes, the plugin lets you leverage its mapping functionality to transfer them via API connections.

How to import and export search terms and synonyms to Magento 2 via ODS files?

Improved Import & Export lets you move search terms and synonyms via ODS files. You no longer need to convert them to CSV to fit the Magento 2 requirements. You can also export data using this file format.

How to import and export search terms and synonyms to Magento 2 via XLSX files?

In addition to ODS, Improved Import & Export lets you move search terms and synonyms via XLSX files. You no longer need to convert them to CSV to fit the Magento 2 requirements. You can also export data using this file format.

How to import and export search terms and synonyms to Magento 2 via JSON files?

Also, Improved Import & Export lets you move search terms and synonyms via XLSX files. You no longer need to convert them to CSV to fit the Magento 2 requirements. You can also export data using this file format.

How to import data to Magento 2 via compressed files?

If your files with search terms and synonyms are compressed, you can transfer them to Magento 2 with the help of the Improved Import & Export extension. Remember that your file archive should be in a ZIP or TAR format. Our module supports compressed CSV, XML, ODS, JSON, and XLSX files.

How to import data to Magento 2 from Google Sheets?

If search terms and synonyms are stored in Google Sheets, it is no longer a problem. You don’t even need to move data files. The Improved Import & Export extension eliminates the necessity to export them from the service, convert them to CSV, and then transfer the output to Magento 2. The module lets you move the corresponding information straight from Google Sheets to your e-commerce website. It is only necessary to specify the address of the corresponding data table.

How to import and export search terms and synonyms to Magento 2 from Dropbox?

The Improved Import & Export module lets you transfer search terms and synonyms to Magento 2 from Dropbox. You can store them there in CSV, JSON, XML, ODS, or XLSX files or ZIP and TAR archives. You can also use this file storage as your export destination.

How to import and export search terms and synonyms to Magento 2 from Google Drive?

In addition to Google Sheets and Dropbox, the Improved Import & Export extension provides the ability to import and export search terms and synonyms between Magento 2 and Google Drive. You can store them there in CSV, JSON, XML, ODS, or XLSX files or ZIP and TAR archives.

Similar Posts