* Skip to main content 
  * Skip to search 
  * Skip to select language 

[ MDN Web Docs  ](/en-US/) Open main menu

  * References  [ References ](/en-US/docs/Web)
    * [ Overview / Web Technology  Web technology reference for developers  ](/en-US/docs/Web)
    * [ HTML  Structure of content on the web  ](/en-US/docs/Web/HTML)
    * [ CSS  Code used to describe document style  ](/en-US/docs/Web/CSS)
    * [ JavaScript  General-purpose scripting language  ](/en-US/docs/Web/JavaScript)
    * [ HTTP  Protocol for transmitting web resources  ](/en-US/docs/Web/HTTP)
    * [ Web APIs  Interfaces for building web applications  ](/en-US/docs/Web/API)
    * [ Web Extensions  Developing extensions for web browsers  ](/en-US/docs/Mozilla/Add-ons/WebExtensions)
    * [ Web Technology  Web technology reference for developers  ](/en-US/docs/Web)
  * Guides  [ Guides ](/en-US/docs/Learn)
    * [ Overview / MDN Learning Area  Learn web development  ](/en-US/docs/Learn)
    * [ MDN Learning Area  Learn web development  ](/en-US/docs/Learn)
    * [ HTML  Learn to structure web content with HTML  ](/en-US/docs/Learn/HTML)
    * [ CSS  Learn to style content using CSS  ](/en-US/docs/Learn/CSS)
    * [ JavaScript  Learn to run scripts in the browser  ](/en-US/docs/Learn/JavaScript)
    * [ Accessibility  Learn to make the web accessible to all  ](/en-US/docs/Web/Accessibility)
  * Plus  [ Plus ](/en-US/plus)
    * [ Overview  A customized MDN experience  ](/en-US/plus)
    * [ AI Help (beta)  Get real-time assistance and support  ](/en-US/plus/ai-help)
    * [ Updates  All browser compatibility updates at a glance  ](/en-US/plus/updates)
    * [ Documentation  Learn how to use MDN Plus  ](/en-US/plus/docs/features/overview)
    * [ FAQ  Frequently asked questions about MDN Plus  ](/en-US/plus/docs/faq)
  * [ Curriculum  New  ](/en-US/curriculum/)
  * [ Blog ](/en-US/blog/)
  * [ Play ](/en-US/play)
  * [ AI Help  Beta  ](/en-US/plus/ai-help)

Search MDN  Clear search input  Search

Theme

  * [ Log in ](/users/fxa/login/authenticate/?next=%2Fen-US%2Fdocs%2FWeb%2FAPI%2FFile)
  * [ Sign up for free  ](/users/fxa/login/authenticate/?next=%2Fen-US%2Fdocs%2FWeb%2FAPI%2FFile)

  1. [ References  ](/en-US/docs/Web)
  2. [ Web APIs  ](/en-US/docs/Web/API)
  3. [ File  ](/en-US/docs/Web/API/File)

Article Actions

  * English (US) 

Filter sidebar  Clear filter input

##  In this article

  * Constructor 
  * Instance properties 
  * Instance methods 
  * Specifications 
  * Browser compatibility 
  * See also 

  1. **[ File API ](/en-US/docs/Web/API/File_API) **
  2. **_[ ` File ` ](/en-US/docs/Web/API/File) _ **
  3. Constructor 
    1. [ ` File() ` ](/en-US/docs/Web/API/File/File)
  4. Instance properties 
    1. [ ` lastModified ` ](/en-US/docs/Web/API/File/lastModified)
    2. [ ` lastModifiedDate ` ](/en-US/docs/Web/API/File/lastModifiedDate) Non-standard  Deprecated 
    3. [ ` name ` ](/en-US/docs/Web/API/File/name)
    4. [ ` webkitRelativePath ` ](/en-US/docs/Web/API/File/webkitRelativePath)
  5. Inheritance 
    1. [ ` Blob ` ](/en-US/docs/Web/API/Blob)
  6. Related pages for File API 
    1. [ ` Blob ` ](/en-US/docs/Web/API/Blob)
    2. [ ` FileList ` ](/en-US/docs/Web/API/FileList)
    3. [ ` FileReader ` ](/en-US/docs/Web/API/FileReader)
    4. [ ` FileReaderSync ` ](/en-US/docs/Web/API/FileReaderSync)

##  In this article

  * Constructor 
  * Instance properties 
  * Instance methods 
  * Specifications 
  * Browser compatibility 
  * See also 

#  File

**Note:** This feature is available in [ Web Workers ](/en-
US/docs/Web/API/Web_Workers_API) .

The **` File ` ** interface provides information about files and allows
JavaScript in a web page to access their content.

` File ` objects are generally retrieved from a [ ` FileList ` ](/en-
US/docs/Web/API/FileList) object returned as a result of a user selecting
files using the [ ` <input> ` ](/en-US/docs/Web/HTML/Element/input) element,
or from a drag and drop operation's [ ` DataTransf