A command-line tool to automatically submit website URLs to Google's Indexing API and Bing's IndexNow API. The tool scans your website's sitemap.xml and submits all URLs for indexing to both search engines.
- Add and manage multiple websites
- Automatically scan sitemap.xml files
- Submit URLs to Google's Indexing API
- Submit URLs to Bing's IndexNow API
- Schedule daily automatic submissions
- Beautiful terminal interface with progress tracking
- Service account authentication for Google (no user interaction required)
- Simple key-based authentication for Bing
- Python 3.7 or higher
- For Google: Google Cloud Project with Indexing API enabled + Service Account credentials
- For Bing: IndexNow API key (generated and hosted on your website)
- Clone the repository:
git clone https://github.com/yourusername/indexpusher.git
cd indexpusher
- Install dependencies:
pip install -r requirements.txt
-
Google Setup (Optional): Download your Service Account credentials from Google Cloud Console and save as
credentials.json
in the project directory. -
Bing Setup (Optional): Generate a Bing IndexNow key and configure it with the tool.
python index_pusher.py add https://example.com
python index_pusher.py set-bing-key your-indexnow-key-here
python index_pusher.py verify-bing-key
python index_pusher.py show-config
python index_pusher.py list
python index_pusher.py submit
python index_pusher.py remove https://example.com
python index_pusher.py schedule
- Go to Google Cloud Console
- Create a new project or select an existing one
- Enable the Indexing API
- Go to IAM & Admin > Service Accounts
- Create a new service account
- Download the JSON key file and save as
credentials.json
in the project directory - Grant the service account the "Indexing API User" role
- Generate an IndexNow key using Bing's online tool or use any 8-128 character hexadecimal string
- Configure the key in the tool:
python index_pusher.py set-bing-key your-key-here
- Important: Create a text file named
{your-key}.txt
in the root of your website containing only your key- Example: If your key is
abc123def456
, createhttps://yourwebsite.com/abc123def456.txt
- The file content should be exactly:
abc123def456
- Example: If your key is
- Verify setup:
python index_pusher.py verify-bing-key
add <url>
- Add a website to monitor (checks for sitemap.xml)set-bing-key <key>
- Configure Bing IndexNow API keyverify-bing-key
- Check if Bing key files are properly hostedshow-config
- Display current configurationlist
- Show all monitored websitessubmit
- Submit all URLs from all monitored websites to Google and Bingremove <url>
- Remove a website from monitoringschedule
- Set up daily automatic submissions at 2:00 AM
- Google: Uses service account authentication (no browser interaction required)
- Bing: Uses key-based authentication (requires hosting key file on your website)
- URLs are submitted with the 'URL_UPDATED' type for Google
- The tool works with either service configured independently or both together
- The scheduler uses crontab for daily execution at 2:00 AM
- Make sure your website has a valid sitemap.xml file
- Rate limiting is handled automatically for both services
- Bing IndexNow allows up to 10,000 URLs per submission