Skip to main content

mkdocs-redirects

Open source plugin for Mkdocs page redirects

Installing

Note: This package requires MkDocs version 1.0.4 or higher.

Install with pip:

pip install mkdocs-redirects

Enable the plugin in your mkdocs.yml:

plugins:
    - redirects

Using

In your mkdocs.yml, add a redirects block that maps the old page location to the new location:

redirects:
  'old': 'some/new_location'
  'something/before': 'another/moved/file'

Note that the .html extension should be omitted (and will be automatically appended).

The plugin will dynamically create old.html and something/before.html in your configured site_dir with HTML that will include a meta redirect to the new page location.

The new location will also be appended with .html extension and is assumed to be relative to the root of the site.

For nested subfolders, the plugin will automatically create these directories in the site_dir.

Contributing

  • Pull requests are welcome.
  • File bugs and suggestions in the Github Issues tracker.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mkdocs-redirects-0.0.2.tar.gz (2.7 kB view details)

Uploaded Source

File details

Details for the file mkdocs-redirects-0.0.2.tar.gz.

File metadata

  • Download URL: mkdocs-redirects-0.0.2.tar.gz
  • Upload date:
  • Size: 2.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.15

File hashes

Hashes for mkdocs-redirects-0.0.2.tar.gz
Algorithm Hash digest
SHA256 587ef0bd2064eccb4a5a8e961eec6b5173afe530a5482791847e7e4c4969d327
MD5 217ddac4f71eaeb32982b86d65fb115e
BLAKE2b-256 9a547cb060d3d248215e176f982f864a0fefca65f5b3157003973f913edef965

See more details on using hashes here.

Release history Release notifications | RSS feed

1.2.3

2 files

1.2.2

2 files

1.2.1

2 files

1.2.0

1 file

1.1.0

1 file

1.0.6

1 file

1.0.5

1 file

1.0.4

1 file

1.0.3

1 file

1.0.2

1 file

1.0.1

1 file

1.0.0

1 file

0.0.6

1 file

0.0.4

1 file

0.0.3

1 file

This release

0.0.2 This release

1 file

0.0.1

1 file

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