What is Algolia

Algolia empowers modern developers to build world class search and discovery experiences without any DevOps.
Libraries with every major language and framework make it easy to enrich your users' experiences. 

Add instant-search to javascript applications

InstantSearch js library is pre-built, customizable and flexible UI widgets to create your own search experiences -  explore the showcase, it has server side rendering and routing capabilities. It is Open source, production-ready and maintained by Algolia.

Get started

FIRST, INSTALL ALGOLIA JAVASCRIPT API CLIENT VIA THE NPM PACKAGE MANAGER: (IF NEEDED, GET A FREE ACCOUNT HERE)


        
          
            

npm install algoliasearch

THEN, CREATE OBJECTS ON YOUR INDEX:


        
          
            

const algoliasearch = require("algoliasearch");

const client = algoliasearch("YourApplicationID", "YourAdminAPIKey");
const index = client.initIndex("your_index_name");

const objects = [
  {
    objectID: 1,
    name: "Foo"
  }
];

index
  .saveObjects(objects)
  .then(({ objectIDs }) => {
    console.log(objectIDs);
  })
  .catch(err => {
    console.log(err);
  });

FINALLY, LET'S ACTUALLY SEARCH USING THE SEARCH METHOD:


        
          
            

index
  .search("Fo")
  .then(({ hits }) => {
    console.log(hits);
  })
  .catch(err => {
    console.log(err);
  });

Enable anyone to build great Search & Discovery