django-json-widget
Django json widget is an alternative widget that makes it easy to edit the jsonfield field of django.
What it is and what it does
django-json-widget is a Django admin and form widget that replaces the default text input for JSONField with a visual JSON editor. It provides syntax highlighting, validation, and a structured editing interface for JSON data, making it easier for users to edit complex JSON structures without manually writing or parsing raw JSON text.
The widget integrates directly into Django's admin interface and forms through standard Django widget overrides. It exposes the underlying editor instance to JavaScript for programmatic access, allowing custom code to manipulate JSON data. Configuration options control editor dimensions and behavior through a dict of options. The package maintains active development with recent fixes for dark mode support and Django version compatibility.
Use it for:
- Editing configuration data stored as JSON in Django admin without writing raw JSON syntax
- Building forms that accept complex nested JSON structures with visual validation feedback
- Providing non-technical users a safer interface to modify JSON fields in production data
- Integrating custom JavaScript logic to programmatically update JSON editor content from other form fields
- Supporting dark mode Django admin themes with automatic color scheme adaptation
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Provides a rich JSON editor widget for Django's admin interface and forms, enabling visual editing of JSONField data with syntax highlighting and validation.
Yes. Low install friction, no runtime dependencies, active maintenance, permissive MIT license, and no known vulnerabilities make this a straightforward choice for Django projects using JSONField. Install if you need a better admin/form interface for JSON editing; skip only if you have no JSONField usage or prefer raw JSON input.
Install
django-json-widget on PyPI
pip
pip install django-json-widgetuv
uv add django-json-widgetpoetry
poetry add django-json-widgetInstalling django-json-widget
Before you install
Low friction installation with no runtime dependencies. Active maintenance with recent releases; last commit 2026-05-08 and latest release 2025-12-12 indicate ongoing support.
License in practice
MIT license (permissive) allows use in both open-source and proprietary projects with minimal restrictions.
Quickstart
pip install django-json-widget
# In settings.py
INSTALLED_APPS = [
...,
'django_json_widget',
]
# In admin.py
from django.contrib import admin
from django.db.models import JSONField
from django_json_widget.widgets import JSONEditorWidget
@admin.register(YourModel)
class YourModelAdmin(admin.ModelAdmin):
formfield_overrides = {
JSONField: {'widget': JSONEditorWidget},
}
Verify before relying
- Whether the widget works with non-PostgreSQL database JSONField implementations (description mentions PostgreSQL-specific fields)
- Performance characteristics with large JSON documents
- Browser compatibility requirements for the embedded JSON editor
Package facts
| License | MIT (permissive) |
| Python support | not specified |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | none |
| Maintenance | actively maintained — 245 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 1,058,474/month — #4,425 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: django_json_widget-2.1.1-py2.py3-none-any.whl
Keywords: django-json-widget
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-aceIntegrates the ACE code editor into Django…
permissive · top 15,000 on PyPI
django-jsoneditorProvides a Django form widget for editing JSON…
unclear · top 15,000 on PyPI
django-jsonformProvides a user-friendly JSON editing form…
permissive · top 15,000 on PyPI
django-prettyjsonAdds a collapsible, interactive JSON viewer…
permissive · top 15,000 on PyPI
django-js-assetAdds script, stylesheet, and JSON tags with…
permissive · top 5,000 on PyPI
djangocms-attributes-fieldProvides a Django model field and widget for…
permissive · top 15,000 on PyPI
django-quill-editorIntegrates Quill.js, a rich-text WYSIWYG…
permissive · top 15,000 on PyPI
django-better-admin-arrayfieldProvides a list-based widget for Django's…
permissive · top 15,000 on PyPI
django-summernoteEmbeds the Summernote WYSIWYG editor into…
permissive · top 15,000 on PyPI
django-tinymcedjango-tinymce provides a Django form widget…
copyleft · top 5,000 on PyPI