A navigation palette for Django admin. Press Cmd+K or Ctrl+K to find models, search records, or jump to a record by primary key.
Supports maintained Python and Django releases. Uses plain JavaScript and CSS, with no frontend dependencies, build step, middleware, or additional URLs.
Start with your models: press Cmd+K or Ctrl+K to browse the models you can access.
Search records: user alice opens the Users list filtered by “alice”.
Jump to a record: user#42 opens the user with primary key 42.
uv pip install django-cmdbarAdd django_cmdbar before django.contrib.admin in INSTALLED_APPS:
INSTALLED_APPS = [
# ...
"django_cmdbar",
"django.contrib.admin",
# ...
]Open Django admin and press Cmd+K or Ctrl+K.
For Django's built-in User model:
| Query | Result |
|---|---|
user |
User list |
user#42 |
User with primary key 42 |
user #42 |
Same record |
user alice |
User list filtered with ?q=alice |
user + |
User creation form |
auth.User |
User list in the auth app |
Type ? or click the ? button to show a short syntax guide.
Matching ignores case and accents and supports abbreviations. Use auth.User or
auth User to distinguish models from different apps.
Names containing spaces use the same syntax, such as Article groups#42.
Search requires configured admin search fields. Use # for an exact primary key;
user 42 performs a text search. String and UUID primary keys are supported.
The palette shows models and actions allowed by your admin permissions. Record names are not previewed; Django checks access when you open a destination.
- Cmd+K or Ctrl+K opens or closes the palette.
- Up and Down select a destination.
- Enter opens the selected destination.
- Cmd+Enter or Ctrl+Enter opens it in a new tab.
- Escape closes the palette.
The palette follows Django admin's light or dark theme.
Custom admin sites and URL prefixes are supported. Each palette lists its site's models.
If your project overrides admin/base_site.html, extend admin/base_site.html
and preserve block.super in the extrastyle and extrabody blocks.
For templates that bypass that chain, add the assets and tag explicitly instead of using Django CmdBar's template extension:
{% extends "admin/base.html" %}
{% load static django_cmdbar %}
{% block extrastyle %}
{{ block.super }}
<link rel="stylesheet" href="{% static 'django_cmdbar/palette.css' %}">
{% endblock %}
{% block extrabody %}
{{ block.super }}
{% django_cmdbar %}
{% endblock %}For a custom admin view that does not expose its site through Django's normal
view wrapper, put the AdminSite instance in the template context and pass it to
the tag:
{% django_cmdbar site=admin_site %}uv sync --python 3.14
uv run playwright install chromium
uv run pytest
uv run ruff check .
uv run ruff format --check .
uv buildDjango CmdBar is under development. Its integration and query syntax can change before the first stable release.


