diff --git a/docs/ref/settings.txt b/docs/ref/settings.txt index fc1f0a8883..cda859a4fa 100644 --- a/docs/ref/settings.txt +++ b/docs/ref/settings.txt @@ -1988,6 +1988,10 @@ unpredictable value. :djadmin:`django-admin startproject ` automatically adds a randomly-generated ``SECRET_KEY`` to each new project. +Uses of the key shouldn't assume that it's text or bytes. Every use should go +through :func:`~django.utils.encoding.force_text` or +:func:`~django.utils.encoding.force_bytes` to convert it to the desired type. + Django will refuse to start if :setting:`SECRET_KEY` is not set. .. warning::