skillfed

django-map-widgets

Configurable and user-friendly map widgets for GeoDjango fields

django-map-widgets v0.6.0 138.0K downloads/30d#11,346 on PyPI470
Permissive license MIT Active released

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-widgets

uv

uv add django-map-widgets

poetry

poetry add django-map-widgets

Installing 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

Development Status :: 5 - Production/StableEnvironment :: Web EnvironmentFramework :: DjangoIntended Audience :: DevelopersLicense :: OSI Approved :: MIT LicenseOperating System :: OS IndependentProgramming Language :: PythonTopic :: Software Development :: Libraries :: Python Modules

Tags

django geodjango map widgetinteractive map form fieldgoogle maps django integrationmapbox leaflet djangogeolocation form widget
geodjangomap-widgetsgeolocation

More Python Modules packages