IndexNow integration

Over 80,000+ companies already use IndexNow every day

IndexNow instantly indexes web content in search engines

IndexNow Implementation Steps

The IndexNow protocol allows you to automatically inform search engines about changes to the site, the appearance of new ones, updating or deleting already indexed pages without waiting for the next crawl by the indexing robot.

  • IndexNow

  • Microsoft Bing

  • Yandex

  • Generate API Key

Generate API key

The API key is required to match ownership of the domain along with submitted URLs; must be at least 8 characters long.

Verify Rights

Place your API key in the root directory in txt format. This will help verify ownership of submitted URLs.

Submit URL

Webmasters can submit individual or bulk URLs. Just send the key location as a URL parameter.


Create an API key

To use IndexNow, upload, preferably in the root directory, a UTF-8 encoded text file with an API key

Generate API Key:

Generate your unique IndexNow key:
IndexNow key
Verify ownership with a key

Download and upload the UTF-8 encoded key file to your site in the root directory (recommended),

the file must contain the key 312a83e32cf7408da2db677bbab5dc83,

the address of the file should look something like this,

https://www.example.com/312a83e32cf7408da2db677bbab5dc83.txt

instead of www.example.com your domain


Use cases for the IndexNow protocol

Option #1: Submit a Single URL

The text file of the key is located in the root directory of your site (http://www.example.com/), in this option it is not required to specify the location of the key file.

https://www.bing.com/indexnow?url=http://www.example.com/product.html&key=312a83e32cf7408da2db677bbab5dc83

HTTP request, to whom we send the URL - Yandex (yandex.com), Microsoft Bing (www.bing.com), IndexNow (api.indexnow.org), url - page of your site, key - key confirming the rights to the site.

Option #2: Submit a Single URL

Placing one or more text key files located not in the root directory, but in other site folders, for example, in the MyFolder folder (http://www.example.com/MyFolder), in this option, you need to specify the location of the key file using the keyLocation parameter.

https://www.bing.com/indexnow?url=http://www.example.com/product.html&key=312a83e32cf7408da2db677bbab5dc83&keyLocation=http://www.example.com/MyFolder/312a83e32cf7408da2db677bbab5dc83.txt

HTTP request, to whom we are sending the URL - Yandex (yandex.com), Microsoft Bing (www.bing.com), IndexNow (api.indexnow.org), url - page of your site, key - key confirming the rights to the site, keyLocation - the location of the text file with the key.

Option #3: Submitting a List of URLs

To send a list of URLs, specify in the JSON content:

Host: <searchengine> - URL provided by search engines, replace with the host name of the search engine, Yandex (yandex.com), Microsoft Bing (www.bing.com), IndexNow (api.indexnow.org)

"host": - address of your site

"key": - the key to confirm the rights to the site

"keyLocation": - location of the key text file

"urlList": - the list of URLs you want to send data about, the list must not exceed 10,000 URLs

Request Format

POST /IndexNow HTTP/1.1
Content-Type: application/json; charset=utf-8
Host: <searchengine>
{
  "host": "www.example.com",
  "key": "192b898092b24bc58786cf5c8e926fd3",
  "keyLocation": "https://www.example.com/192b898092b24bc58786cf5c8e926fd3.txt",
  "urlList": [
      "https://www.example.com/url1",
      "https://www.example.com/folder/url2",
      "https://www.example.com/url3"
      ]
}

Note

The location of the key file defines the list of URLs that can be included in this key.

The key file located at: http://example.com/catalog/312a83e32cf7408da2db677bbab5dc83.txt, can include any URL starting with http://example.com/catalog/ but cannot include URLs starting from http://example.com/help/, http://example.com/blog/, http://example.com/image/ etc..

URLs are accepted for indexing

http://example.com/catalog/show?item=23

http://example.com/catalog/show?item=233&user=3453

URLs are considered invalid and will not be accepted for indexing

http://example.com/image/show?item=23

http://example.com/image/show?item=233&user=3453

To get the most out of using the IndexNow protocol, it is highly recommended that you place the key text file in the root directory of your website.

Request Format
HTTP codeResponseReasons
200OKURL submitted successfully
202AcceptedURL received. IndexNow key validation pending.
400Bad requestInvalid format
403ForbiddenIn case of key not valid (e.g. key not found, file found but key not in the file)
422Unprocessable EntityIn case of URLs which don’t belong to the host or the key is not matching the schema in the protocol
429Too Many RequestsToo Many Requests (potential Spam)

Try Xone IndexNow free for 3 days

Instant indexing in Yandex, Microsoft Bing, IndexNow.

Start Free Trial
content-image
Xone indexing module

Send an array of URLs using the IndexNow protocol

Advanced features

Get more customers with Xone IndexNow universal indexing module

Buy now

instant indexing

Ready to grow your business?

The Xone IndexNow indexing module will help you dominate the search engines, quickly inform you about all changes to the content on the site, the appearance of new ones, updating or deleting already indexed pages.

Discover a comprehensive marketing solution that drives business growth, powerful features to increase productivity and increase sales.

Feel the freedom and power of the IndexNow protocol, use just one universal indexing module Xone, promoting products and services in search engines for an unlimited number of websites.



How to use Curl to submit URLs İn Bulk With İndexNow API?

Two cases of the appearance of a list of URLs are considered, in which arrays of links are found, but all of them are found from different sources without exception.

The first will be the sitemap.xml file that almost every site has, the next one is a simple text file.

Below are examples of using Curl to bulk send URLs using the İndexNow API from a sitemap.xml file or plain text file that offers a link request, each link starts with the string (download file).

Array of URLs from sitemap.xml Array of URLs from link.txt

Working Curl code to bulk send URLs using the İndexNow API from a text file.

Let's slightly change the code below, move the parameters to a separate file, add a form for sending data via AJAX and display html (response) of the result of the JSON request. Full code and manual »

Copy code

  1. <?php
  2. ini_set('error_reporting', E_ALL);
  3. ini_set('display_errors', 1);
  4. ini_set('display_startup_errors', 1);
  5. //-- Options --//
  6. $count = 0;
  7. $dlm = "|~|"; // Pseudo delimiter
  8. $dlmBreack = "\n"; // Delimiter
  9. $dlmCount = "10000"; // Limiting the number of lines read from the file
  10. $txtfile = "url.txt"; // Data file containing a list of URLs
  11. $IndexNowKey = "6352b4ae24df467dbffe0adb9438cd28"; // Key IndoxNew
  12. $uRoor = "example.com"; // Domain
  13. $uHttps = "https"; // http or https
  14. $uEngine = "www.bing.com"; // To whom we transfer data - yandex.com, www.bing.com or api.indexnow.org
  15. //-- Options --//
  16. $uRLS = "".$uHttps."://$uRoor/"; // Final Url with protocol http or https
  17. $txtfile = preg_replace("!^s+!m", "", $txtfile); // Trim spaces at the beginning of the string
  18. $txtfile = preg_replace("![\n\r]+\s*[\n\r]+!", "\r\n", $txtfile); // Remove empty lines
  19. $DoLink = file_get_contents($txtfile);
  20. $Link = explode($dlmBreack, $DoLink, $dlmCount);
  21. for($in = 0; $in < count($Link); $in++){
  22. $Urls = explode($dlm, $Link[$in]);
  23. $uUrl = $Urls[0]; // String with link
  24. if ($uUrl!=='') { $BLGe[]="$uUrl"; $count++; } // Create an array of links
  25. }
  26. $data = array('host' => "$uRoor", 'key' => "$IndexNowKey", 'keyLocation' => "".$uRLS."".$IndexNowKey.".txt", 'urlList' =>array_reverse(array_reverse($BLGe)));
  27. $data_string = json_encode($data);
  28. $ch = curl_init("https://$uEngine/indexnow");
  29. curl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type:application/json; charset=utf-8'));
  30. curl_setopt($ch, CURLOPT_POST, 1);
  31. curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($data, JSON_UNESCAPED_UNICODE));
  32. curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
  33. curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
  34. curl_setopt($ch, CURLOPT_HEADER, false);
  35. $res = curl_exec($ch);
  36. $result = curl_exec($ch);
  37. $http_code = (int) curl_getinfo($ch, CURLINFO_HTTP_CODE);
  38. curl_close($ch);
  39. $res = json_encode($res, JSON_UNESCAPED_UNICODE);
  40. if ($http_code == 200) { echo "<div class=\"alert alert-success text-center\" role=\"alert\">$http_code <b>OK - Prepared and successfully submitted $count URLs</b></div><div class=\"alert alert-secondary text-center\" role=\"alert\">site - <b>$uHost</b>, request - <b>$uEngine</b></div>"; }
  41. elseif ($http_code == 202) { echo "<div class=\"alert alert-primary text-center\" role=\"alert\">$http_code <b>Prepared and sent successfully $count URLs, pending verification of the IndexNow key</b></div><div class=\"alert alert-secondary text-center\" role=\"alert\">site - <b>$uHost</b>, request - <b>$uEngine</b></div>"; }
  42. elseif ($http_code == 400) { echo "<div class=\"alert alert-danger text-center\" role=\"alert\">$http_code <b>Invalid request. Wrong format</b></div><div class=\"alert alert-secondary text-center\" role=\"alert\">site - <b>$uHost</b>, request - <b>$uEngine</b></div>"; }
  43. elseif ($http_code == 403) { echo "<div class=\"alert alert-danger text-center\" role=\"alert\">$http_code <b>Forbidden. Invalid key (e.g. key not found, file found but key not in file)</b></div><div class=\"alert alert-secondary text-center\" role=\"alert\">site - <b>$uHost</b>, request - <b>$uEngine</b></div>"; }
  44. elseif ($http_code == 422) { echo "<div class=\"alert alert-danger text-center\" role=\"alert\">$http_code <b>Unprocessed object. The URLs do not belong to the host or the key does not match the scheme in the protocol</b></div><div class=\"alert alert-secondary text-center\" role=\"alert\">site - <b>$uHost</b>, request - <b>$uEngine</b></div>"; }
  45. elseif ($http_code == 429) { echo "<div class=\"alert alert-danger text-center\" role=\"alert\">$http_code <b>Too many requests. Counted as potential spam</b></div><div class=\"alert alert-secondary text-center\" role=\"alert\">site - <b>$uHost</b>, request - <b>$uEngine</b></div>"; }
  46. else { echo "<div class=\"alert alert-danger text-center\" role=\"alert\">$http_code -<b> Error sending list of URLs</b></div>";
  47. ?>

Using the buttons below, submit an array of URLs using the İndexNow API from a sitemap.xml file or a text file.

Array of URLs from sitemap.xml Array of URLs from link.txt

Over 80,000 sites around the world are actively using Xone IndexNow

80K

Happy Customers
IndexNow

4.86

8,376 Rating

Everything you need to know before getting started

I submitted a URL, what happens next?

If the URLs are standards compliant, IndexNow ensures that search engines are aware of changes to your site based on scheduling logic and crawl quota.

Can I submit the same URL many times in a day?

We strongly recommend that you do not send the same URL many times a day. If pages are edited frequently, then it is advisable to wait 10 minutes between changes before notifying search engines, if pages are updated constantly (eg time, weather, exchange rates), it is advisable not to use IndexNow for every change.

Can I submit 404 URLs via API?
  • Yes, to notify search engines of new broken links, you can submit broken pages (http 404, http 410).

I got an HTTP 429 Too Many Requests response from a search engine, what is the reason?

This code indicates that you are sending too many requests in a short period of time, reduce the frequency of sending requests and try again later.

Can I use more than one key?

Yes, if your websites use different content management systems, each can use its own key located at the root of the host.

I have a sitemap, do I need IndexNow?
  • Yes, although a sitemap file serves as an easy way to inform search engines about all the pages on a site.

    With IndexNow, you don't have to wait until the sitemap is crawled, but directly notify search engines about the appearance of new, updating or deleting already indexed pages.

Have more questions? Ask your question here

Try Xone IndexNow free for 3 days

Instant indexing in Yandex, Microsoft Bing, IndexNow.

Start Free Trial