</>
Sitemap.xml Docs
Docs Getting Started Introduction

Welcome to Sitemap.xml

Sitemap.xml is a modern, developer-first platform that automates sitemap generation, search engine indexing, and crawl optimization. Whether you're running a small blog or a multi-million page e-commerce platform, our infrastructure ensures your content is discovered, understood, and ranked efficiently.

💡 Quick Start: If you're in a hurry, jump to Installation or check out our 10-minute interactive tutorial.

Installation

The fastest way to integrate Sitemap.xml into your project is via our official CLI or SDK. Support is available for Node.js, Python, Go, and PHP.

npm
# Install the CLI globally
npm install -g @sitemap/cli

# Or add to your project
npm install @sitemap/sdk
Python
pip install sitemap-xml-py

# Initialize your project
sitemap init

Basic Configuration

Create a sitemap.config.js file in your project root. This is where you define your base URL, crawl rules, and output preferences.

sitemap.config.js
module.exports = {
  baseUrl: 'https://yourdomain.com',
  output: 'public/sitemap.xml',
  crawl: {
    maxDepth: 5,
    delay: 100, // ms between requests
    ignore: ['/admin/', '/api/', '*.css'],
  },
  submitTo: ['google', 'bing', 'yandex'],
  priority: 0.8,
  changefreq: 'daily'
};
⚠️ Note: Ensure your baseUrl matches your production environment. Mismatched domains will cause indexing failures or duplicate content penalties.

Core API Endpoints

Once configured, the Sitemap.xml dashboard exposes a RESTful API for programmatic control. All requests require a Bearer token.

Method Endpoint Description Rate Limit
GET /v1/sitemap Fetch current sitemap XML or JSON 120 req/min
POST /v1/generate Trigger immediate sitemap rebuild 10 req/min
POST /v1/submit Push URLs to search engines 50 req/min
GET /v1/analytics Crawl status & index coverage 60 req/min

Authentication

All API requests must include your project API key in the Authorization header:

cURL
curl -X GET https://api.sitemap.xml/v1/sitemap \\
  -H "Authorization: Bearer YOUR_API_KEY" \\
  -H "Content-Type: application/json"
✅ Best Practice: Store your API keys in environment variables or a secrets manager. Never commit them to version control.
Last updated: Jan 15, 2025
Getting Started
Quick installation, configuration, and first deployment.
API Reference
Complete endpoint documentation, auth, and rate limits.
WordPress Integration
Step-by-step guide for WP sites & multisite networks.