All of our Drupal installations have a /tmp folder at the root of the installation (ie, in parallel with the core files).

What does Drupal use the temporary directory for?

  • To keep temporary files? Listing of all situations when file will be temporary is impossible, as it would grow with about every third module released.
    – Mołot
    Dec 24, 2013 at 13:28
  • 1
    @Mołot A good answer doesn't have to outline all uses of the tmp directory, but it could explain the common ones. This is a perfectly acceptable question.
    – mpdonadio
    Dec 24, 2013 at 13:33
  • @MPD if OP would ask for common ones, OK. If he would simply ask for applications, OK too. But he explicitly asks for all, and that's too much IMO.
    – Mołot
    Dec 24, 2013 at 13:39
  • @Mołot That's not what was asked. This can simply be edited to make it clearer instead of closing.
    – mpdonadio
    Dec 24, 2013 at 14:15

1 Answer 1


Your temporary directory holds files before they actually move to the appropriate position in your files directory.

Not sure but I think one the example can be the time we upload a file in a content type it first goes to tmp directory before you actually save the node. Also you might have image cache working if file type is image so the file must exist on server before it crops or scale, so tmp is that directory.

Also the tmp folder is always need to be in drupal root directory, the place is configurable from settings.

Not the answer you're looking for? Browse other questions tagged or ask your own question.