Skip to main content

Excel to Sitemap (xl2sitemap)

PyPI version

Xl2sitemap is a command line tool to generate sitemaps using data in an excel sheet. Xl2sitemap reads data from an excel sheet and converts the data into SEO friendly sitemaps that can be submitted to search engines directly after uploading.

  • Generates a .xml file
  • Generates a .xml.gz file (compressed)
  • Gives you flexibility with the number of urls in a single file

New Features!

  • Ability to create multiple sitemaps based on classifiers. Classifiers are nothing but different groups for which it is ideal to create different sitemaps. This makes it easier for indexation problem debugging as mentioned on the blog XML Sitemaps by Moz

You can also:

  • Add attributes such as priority, changefreq, lastmod to your urlsets

Requirements

Dillinger uses a number of open source projects to work properly:

  • Python 3 - Python 3 and above
  • A well structured excel file with appropriate column names as mentioned below

Structuring your excel sheet

Excel sheet format

  • The column url is a compulsory column in your excel sheet. This contains the urls of your website
  • The classifier column is an optional column. This contains the classifier based on which the sitemap file will be split into multiple files. If you are including this column in your excel sheet, make sure you use the -c flag
  • The lastmod column is an optional column. This contains the last modified date of the corresponding url in DD/MM/YYYY format. If you are including this column in your excel sheet, make sure you use the -l flag
  • The changefreq column is an optional column. This contains the last change frequency of the corresponding url. If you are including this column in your excel sheet, make sure you use the -f flag
  • The priority column is an optional column. This contains the priority of the corresponding url. If you are including this column in your excel sheet, make sure you use the -p flag

Installation

Installation of xl2sitemap requires running the following command form your command line utility

pip install xl2sitemap

Running from command line

Running xl2sitemap with the basic default configuration requires running the following command

xl2sitemap example-input.xlsx

The example-input.xlsx can be any excel sheet with the appropriate columns in it

Other options that can be enabled are

Flag Usage
-f Will add <changefreq> tag in your sitemap
-p Will add <priority> tag in your sitemap
-l Will add <lastmod> tag in your sitemap
-c Will split sitemap into multiple files based on the classifier column
-m 50000 Will add a maximum of 50,000 urls only in a single sitemap. If urls are greater than 50,000 then multiple files will be generated

Example

xl2sitemap example-input.xlsx -m 40000 -p -f -l

This will generate sitemaps with 40,000 urls in each file with <changefreq>, <priority>, <lastmod> attributes for each <urlset>.

Development

Want to contribute? Great! Open your favorite Terminal and run these commands.

git clone https://github.com/antiproblemist/excel-to-sitemap.git

License

BSD 3-Clause

Author

Follow the author on Linkedin

Free Software, Hell Yeah!

Metadata

Release files for xl2sitemap 0.1.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for xl2sitemap 0.1.3
File Size Uploaded
xl2sitemap-0.1.3.tar.gz 4.9 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for xl2sitemap 0.1.3
File Interpreter ABI Platform
xl2sitemap-0.1.3-py3-none-any.whl Python 3 none any Details

Total release size: 11.5 kB

Release files / xl2sitemap-0.1.3.tar.gz

Download URL xl2sitemap-0.1.3.tar.gz
Size 4.9 kB
Tags Source
SHA-256 checksum
How to use checksums
7e719784fa69f6a1d4d9bb9dfc44f5689a3da1ffdd8a06ac470dd6ff4dc3078c
BLAKE2b-256 checksum
How to use checksums
114cb21e49f333d94e929a3c1fdbbb703a4cc531c2d48d0c2cc592b3bdcb1af9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.7.3

Release files / xl2sitemap-0.1.3-py3-none-any.whl

Download URL xl2sitemap-0.1.3-py3-none-any.whl
Size 6.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
52f040a913c496366666fe4f3c7667eab5ef64b06482087d4a49ff746dbaa774
BLAKE2b-256 checksum
How to use checksums
34068169ef6144f3357782b3414a937f99867cbe0f13a4ff0955e7f33bc6e9ed
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.7.3

Release history Release notifications | RSS feed

This release

0.1.3 This release

2 release files

0.1.2

2 release files

0.1.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page