# How to only compile the included tex file?

Suppose we are given a big main .tex file. I wish to use the command \include to import all the other .tex files into the mail .tex file. I heard that to save time, one can in fact only compile the particular file included. But how can I do that if the included .tex file does not have a document class or proper setup for it to typeset on its own?

You can use \includeonly command:
\documentclass{book}

Now only the nextfile will be compiled but all the numbers and other cross reference are properly displayed.