 <p><strong>Django 1.9</strong> <code>settings.py</code>:</p> <pre><code>INTERNAL_IPS = ( '127.0.0.1', ) </code></pre> <p>Templates:</p> <pre><code>{% if debug %} </code></pre> <p><a href="https://docs.djangoproject.com/en/1.9/ref/settings/#std:setting-INTERNAL_IPS" rel="nofollow">https://docs.djangoproject.com/en/1.9/ref/settings/#std:setting-INTERNAL_IPS</a> says:</p> <blockquote> <p>A list of IP addresses, as strings, that:</p> <ul> <li>Allow the debug() context processor to add some variables to the template context.</li> </ul> </blockquote> <p>The <code>debug</code> context processor is in the default <code>settings.py</code>.</p>