Lightweight Python package that makes it easy to submit URLs to the IndexNow API of various search engines
Project description
🔍 Submit URLs to the IndexNow API of Various Search Enginges 🔎
Are you concerned about search engine optimization (SEO)? Do you want to make sure your website is indexed frequently by Bing, Yandex, and other search engines?
IndexNow for Python is a lightweight Python package that makes it easy to submit URLs or entire sitemaps to the IndexNow API of various search engines, so your pages can be indexed faster.
Ready to try? Learn how to install and find tutorials in the user guide.
Getting Started
Basic Usage and Submit Individual URLs
Firstly, ensure that you have an API key for IndexNow. Hereafter, add your authentication details to the IndexNowAuthentication class, which will be used throughout the examples:
from index_now import submit_url_to_index_now, IndexNowAuthentication
authentication = IndexNowAuthentication(
host="example.com",
api_key="a1b2c3d4",
api_key_location="https://example.com/a1b2c3d4.txt",
)
You can now submit individual URLs to the IndexNow API:
submit_url_to_index_now(authentication, "https://example.com/page1")
Submit Multiple URLs in Bulk
How to submit multiple URLs in bulk to the IndexNow API:
from index_now import submit_urls_to_index_now, IndexNowAuthentication
authentication = IndexNowAuthentication(...)
urls = [
"https://example.com/page1",
"https://example.com/page2",
"https://example.com/page3",
]
submit_urls_to_index_now(authentication, urls)
Submit Entire Sitemap
How to submit an entire sitemap to the IndexNow API:
from index_now import submit_sitemap_to_index_now, IndexNowAuthentication
authentication = IndexNowAuthentication(...)
sitemap_url = "https://example.com/sitemap.xml"
submit_sitemap_to_index_now(authentication, sitemap_url)
Submit to Specific Search Engines
How to use the default SearchEngineEndpoint options or a custom endpoint:
from index_now import submit_url_to_index_now, IndexNowAuthentication, SearchEngineEndpoint
authentication = IndexNowAuthentication(...)
endpoint_bing = SearchEngineEndpoint.MICROSOFT_BING
endpoint_custom = "https://example.com/indexnow"
for endpoint in [endpoint_bing, endpoint_custom]:
submit_url_to_index_now(authentication, "https://example.com/page1", endpoint)
Become a Sponsor 🏅
If you find this project helpful, please consider supporting its development. Your donations will help keep it alive and growing. Every contribution, no matter the size, makes a difference.
Thank you for your support! 🙌
Contribute
If you have suggestions or changes to the module, feel free to add to the code and create a pull request.
Report Bugs
Report bugs and issues here.
MIT License
Copyright (c) 2025 – present, Jakob Bagterp
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file index_now_for_python-0.1.0.tar.gz.
File metadata
- Download URL: index_now_for_python-0.1.0.tar.gz
- Upload date:
- Size: 9.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
64b50be5b222afd6296d54031f7032404bd2f02486bf546ce8871ddd0aa9a702
|
|
| MD5 |
0c2f43a63cccad4f899d43dd58db73c0
|
|
| BLAKE2b-256 |
05e52cd1c7a0b8c63363b1450b48b10487e99d313b659cad32158f3b807e3f69
|
Provenance
The following attestation bundles were made for index_now_for_python-0.1.0.tar.gz:
Publisher:
release.yml on jakob-bagterp/index-now-for-python
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
index_now_for_python-0.1.0.tar.gz -
Subject digest:
64b50be5b222afd6296d54031f7032404bd2f02486bf546ce8871ddd0aa9a702 - Sigstore transparency entry: 210664192
- Sigstore integration time:
-
Permalink:
jakob-bagterp/index-now-for-python@7452de96251031c431fbdf5cae42f689d4dd173a -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/jakob-bagterp
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@7452de96251031c431fbdf5cae42f689d4dd173a -
Trigger Event:
push
-
Statement type:
File details
Details for the file index_now_for_python-0.1.0-py3-none-any.whl.
File metadata
- Download URL: index_now_for_python-0.1.0-py3-none-any.whl
- Upload date:
- Size: 9.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a4907468b16b2384e6b155b0f9037468d0d40859adcf8c9b31e5f83045ddb4cc
|
|
| MD5 |
af9935bcdd93d3a08b1ae19eb811d76b
|
|
| BLAKE2b-256 |
b33ac75ea663bda131adb051fc1f6b001e5c1fb81c7586e36210e7b133b1fe01
|
Provenance
The following attestation bundles were made for index_now_for_python-0.1.0-py3-none-any.whl:
Publisher:
release.yml on jakob-bagterp/index-now-for-python
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
index_now_for_python-0.1.0-py3-none-any.whl -
Subject digest:
a4907468b16b2384e6b155b0f9037468d0d40859adcf8c9b31e5f83045ddb4cc - Sigstore transparency entry: 210664196
- Sigstore integration time:
-
Permalink:
jakob-bagterp/index-now-for-python@7452de96251031c431fbdf5cae42f689d4dd173a -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/jakob-bagterp
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@7452de96251031c431fbdf5cae42f689d4dd173a -
Trigger Event:
push
-
Statement type: