How to Make Your Django Forms Look Crispy 🥓

Ordinary Coders
Level Up Coding
Published in
4 min readMar 2, 2021

--

Django’s built-in form features are great when it comes to functionality but lack a stylized appearance. Luckily there is a Python package called django crispy forms that styles Django forms CSS for you using built-in template packs.

If you are new to using Django forms, then learn how to build a Django form first before moving on to the styling.

How to use Django crispy forms

  1. pip install django-crispy-forms in your Django project
  2. add crispy_forms to the list of installed apps in the settings
  3. add the crispy_template_pack to the settings
  4. load in the Django crispy_forms_tags in the HTML template
  5. add the |crispy or |as_crispy_field filter to the Django form variable

How to install Django crispy forms

To use this package, you need to first pip install django crispy forms then add it to your Django project settings.

--

--

Coding can be difficult. Get motivated by learning to code with interactive, step-by-step tutorials. https://ordinarycoders.com/