Official ElasticPress integration for Frontity

Usage no npm install needed!

<script type="module">
  import 10upFrontityElasticpress from 'https://cdn.skypack.dev/@10up/frontity-elasticpress';



This package enhances your frontity theme by supercharing the search experience with ElasticPress.

Support Level



To install this package you will need an existing frontity project. Check out the frontity docs for instructions.

Install this package:

npm install @10up/frontity-elasticpress --save

Then in your frontitiy.settings.[js|ts] add the configuration for ElasticPress in the packages section.

            name: '@10up/frontity-elasticpress',
            state: {
                elasticpress: {
                    node: 'http://elasticpress.test/__elasticsearch',
                    indexName: 'elasticpresstest-post-1',
                    loadInitialData: true,

That's all you need.

How it works

This packages replaces the default search handler with a custom one that runs search queries in ElasticSearch index directly instead of WordPress.

In addition to better search results this also allow you to have real-time search results as you type. See an example here.


You need to ensure your ElasticSearch index is not fully exposed to the public. You most likely want to add some layer around your ElasticSearch index to lock down your index to avoid unwanted queries or requests.

Check out ElasticPress.io for a secure ElasticSearch service that was built for ElasticPress.

Like what you see?

Work with us at 10up