django-ordered-model
Allows Django models to be ordered and provides a simple admin interface for reordering them.
What it is and what it does
django-ordered-model is a Django app that lets you add ordering to any model by inheriting from a base class instead of models.Model directly. It maintains an order field and provides methods to move instances relative to each other—up, down, to a specific position, above or below another instance, or to the top or bottom of the stack. It also supports subset ordering so you can order items independently within groups, such as each user's contacts ordered separately.
The package includes a custom manager and queryset with additional filtering methods, and integrates with Django's admin interface for reordering. It uses Django's update() method for performance when shifting other objects' positions. The codebase is marked Production/Stable but maintenance is dormant with no releases since 2023-03-17.
Use it for:
- Manage a ranked or prioritized list of items in a Django app where users can reorder via admin.
- Order contacts, tasks, or other entities independently per user or group using subset ordering.
- Build a many-to-many relationship with custom ordering via a through model.
- Implement a sortable list of questions or content blocks where position matters and can change dynamically.
- Query for items above or below a threshold position without manually managing sort indices.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Adds ordering and reordering capabilities to Django models, with methods to move instances up, down, to specific positions, or relative to other instances, plus admin UI support.
Yes, if you need model ordering in Django and can accept dormant maintenance. The package is stable, has no security vulnerabilities, installs with zero friction, and solves a common problem cleanly. However, verify compatibility with your Django version since the last release was 2023-03-17 and no updates are planned.
Install
django-ordered-model on PyPI
pip
pip install django-ordered-modeluv
uv add django-ordered-modelpoetry
poetry add django-ordered-modelInstalling django-ordered-model
Before you install
Low friction install with no runtime dependencies. Maintenance is dormant—last release was 2023-03-17 and no commits since 2024-11-15—so expect no active bug fixes or feature updates, though marked Production/Stable.
License in practice
Licensed under BSD (permissive), so you can use, modify, and distribute this package freely in commercial and private projects with minimal restrictions.
Quickstart
pip install django-ordered-model
# In settings.py, add 'ordered_model' to INSTALLED_APPS
from django.db import models
class Item(models.Model):
name = models.CharField(max_length=100)
# After inheriting from OrderedModel and migrating:
foo = Item.objects.create(name="Foo")
bar = Item.objects.create(name="Bar")
foo.swap(bar)
foo.up()
foo.to(5)
Requires Django to be installed and configured; models must be migrated after inheriting from OrderedModel.
Verify before relying
- Whether the package works with Django versions released after 2023-03-17
- Whether subset ordering scales well with large datasets
- Current compatibility with modern Python and Django releases
Package facts
| License | not declared (permissive) |
| Python support | not specified |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | none |
| Maintenance | dormant — 1,246 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 719,437/month — #5,240 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: django_ordered_model-3.7.4-py3-none-any.whl
Tags
More Front-Ends packages
SQLAlchemy is a Python SQL toolkit and Object…
permissive · top 100 on PyPI
psycopg2-binarypsycopg2-binary is a PostgreSQL database…
copyleft · top 1,000 on PyPI
alembicAlembic generates and manages database schema…
permissive · top 1,000 on PyPI
weaviate-clientA Python client library for connecting to and…
permissive · top 1,000 on PyPI
databricks-sql-connectorA Python client library that connects to…
permissive · top 1,000 on PyPI
psycopgPsycopg 3 is a PostgreSQL database adapter for…
copyleft · top 1,000 on PyPI
django-admin-sortable2Adds drag-and-drop reordering of model…
permissive · top 5,000 on PyPI
django-reverse-adminAdds reverse inline support to Django admin for…
permissive · top 15,000 on PyPI
django-modelclusterdjango-modelcluster extends Django models to…
permissive · top 5,000 on PyPI
orderingsProvides an Ordering enumeration and Compare…
permissive · top 15,000 on PyPI
swapperSwapper provides an API for Django's…
permissive · top 15,000 on PyPI
modelsearchIndexes Django models into Elasticsearch,…
permissive · top 15,000 on PyPI
django-lifecycleAdds declarative lifecycle hooks to Django…
permissive · top 15,000 on PyPI
model-bakeryModel Bakery creates test fixtures for Django…
permissive · top 5,000 on PyPI
django-soft-deleteAdds soft deletion to Django models by marking…
permissive · top 15,000 on PyPI
django-tree-queriesQuery hierarchical tree structures in Django…
permissive · top 15,000 on PyPI