django-map-widgets
Configurable and user-friendly map widgets for GeoDjango fields
What it is and what it does
Django Map Widgets bridges GeoDjango's geographic field types with user-friendly, interactive map interfaces in Django admin and forms. It wraps Google Maps, Mapbox, and Leaflet to provide point-field widgets—both interactive (for editing locations via click or drag) and static (for read-only display)—eliminating the need to build custom map UIs from scratch.
The package is configured entirely through Django settings, allowing you to customize map behavior (zoom, center, marker options) and provider-specific features (API keys, place autocomplete) without touching widget code. It handles asset collection and jQuery integration automatically in admin, and requires minimal template setup in custom views. Currently limited to PointField support across all providers, with LineString and other geometry types not yet supported.
Use it for:
- Build admin interfaces where staff can click a map to set or edit geographic point coordinates instead of typing latitude/longitude.
- Create public-facing forms that let users select a location interactively before submitting an address or venue.
- Display read-only maps in Django templates showing stored point locations without allowing user interaction.
- Integrate place autocomplete into map widgets to help users find and confirm addresses during data entry.
- Switch between map providers by changing settings without rewriting form or admin code.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Provides interactive and static map widgets for Django GeoDjango form fields, supporting Google Maps, Mapbox, and Leaflet with point-field editing and display.
Yes. Active maintenance, no security issues, permissive license, and zero runtime dependencies make it low-risk. Install friction is minimal. Suitable if you need interactive or static point-field maps in Django admin or forms and want to avoid building custom map UIs—but only if your use case is limited to PointField; other GeoDjango geometry types are not yet supported.
Install
django-map-widgets on PyPI
pip
pip install django-map-widgetsuv
uv add django-map-widgetspoetry
poetry add django-map-widgetsInstalling django-map-widgets
Before you install
Low install friction with no runtime dependencies. Active maintenance: last commit 2026-07-31, 26 days since latest release. Requires Python >=3.10 and Django; jQuery 3.7-slim needed for non-admin views.
License in practice
MIT license (permissive) places no restrictions on use, modification, or distribution in proprietary or open-source projects.
Quickstart
pip install django-map-widgets
# In settings.py
INSTALLED_APPS = [..., 'mapwidgets']
# In admin.py
from django.contrib.gis.db import models
class CityAdmin(admin.ModelAdmin):
formfield_overrides = {
models.PointField: {"widget": GoogleMapPointFieldWidget}
}
Requires Django with GeoDjango (django.contrib.gis) configured; Google Maps or Mapbox API keys needed if using those providers; jQuery 3.7-slim required for non-admin views.
Verify before relying
- Whether LineString, Polygon, and Multi* GeoDjango fields are planned for future support beyond PointField.
- Performance characteristics when handling large numbers of map widgets on a single page.
- Compatibility with recent Django and Python versions beyond the stated >=3.10 requirement.
Package facts
| License | MIT (permissive) |
| Python support | supports the current Python release (>=3.10) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | none |
| Maintenance | actively maintained — 26 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 138,048/month — #11,346 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: django_map_widgets-0.6.0-py3-none-any.whl
Keywords: django, map-widgets, geodjango, geolocation, mapbox, google, map, leaflet, interactive-maps
Tags
More Python Modules packages
Converts domain names between Unicode and…
permissive · top 100 on PyPI
setuptoolsSetuptools is a Python build backend and…
permissive · top 100 on PyPI
PyYAMLPyYAML parses and emits YAML 1.1 data format,…
permissive · top 100 on PyPI
pydanticPydantic validates Python data structures…
permissive · top 100 on PyPI
annotated-typesProvides reusable metadata objects for use with…
permissive · top 100 on PyPI
typing-inspectionProvides runtime tools to inspect and…
permissive · top 100 on PyPI
django-leafletIntegrates the Leaflet JavaScript mapping…
copyleft · top 15,000 on PyPI
jupyter-leafletjupyter-leaflet provides interactive map…
permissive · top 15,000 on PyPI
django-prettyjsonAdds a collapsible, interactive JSON viewer…
permissive · top 15,000 on PyPI
keplerglA Jupyter widget that embeds kepler.gl's…
unclear · top 15,000 on PyPI
ipyleafletipyleaflet embeds interactive Leaflet maps…
permissive · top 15,000 on PyPI
django-json-widgetProvides a rich JSON editor widget for Django's…
permissive · top 5,000 on PyPI
django-js-assetAdds script, stylesheet, and JSON tags with…
permissive · top 5,000 on PyPI
django-jsonformProvides a user-friendly JSON editing form…
permissive · top 15,000 on PyPI
django-jsoneditorProvides a Django form widget for editing JSON…
unclear · top 15,000 on PyPI