Getting Started
===============

Installation
------------

Directly install via ``pip`` by using:

.. code::

   pip install sphinx-sitemap

Or with ``conda`` via ``conda-forge``:

.. code::

   conda install -c conda-forge sphinx-sitemap

Usage
-----

Add ``sphinx_sitemap`` to :confval:`extensions` in your Sphinx **conf.py**.
For example:

.. code:: python

   extensions = ['sphinx_sitemap']

Set the value of :confval:`html_baseurl` in your Sphinx **conf.py** to the current
base URL of your documentation. For example:

.. code:: python

   html_baseurl = 'https://my-site.com/docs/'

After the HTML finishes building, **sphinx-sitemap** will output the location of the sitemap::

    sitemap.xml was generated for URL https://my-site.com/docs/ in /path/to/_build/sitemap.xml

.. tip:: Make sure to confirm the accuracy of the sitemap after installs and upgrades.

See :doc:`advanced-configuration` for more information about how to use **sphinx-sitemap**.
