File descriptors are pointer to file structures. Normally, we have 3 file descriptors reserverd i.e 0(stdin), 1 (stdout) and 2(stderr). File descriptors are reference to open files, sockets, pipes or other I/O resources that a process can read from or write to.