<p>In Django templates, is there a variable in the context (e.g. <code>{{ BASE\_URL }}</code>, <code>{{ ROOT\_URL }}</code>, or <code>{{ MEDIA\_URL }}</code> that one can use to link to the <code>home</code> url of a project?</p>

<p>I.e. if Django is running in the root of a project, the variable (let's call it R) <code>{{ R }}</code> in a template would be <code>/</code>. If the root url is a sub-folder <code>http://host/X/</code> the variable <code>{{ R }}</code> would be <code>/X/</code> (or <code>http://host/X/</code>).</p>

<p>It seems painfully simple, but I can't find an answer. :) Thank you!</p>

I always use something like
```
<a href="/">
```
(assuming your home is at the root, of course). I seem to recall looking this up once, and couldn't find a Django variable for this path; at any rate,
```
/
```
seemed pretty easy, anyway.