Possible Duplicate:
how to create a template or document class for latex?

Currently, whenever I create a new document, I add a reference in the header to


where header.tex contains a whole bunch of package imports and default settings I like to use. Is there a way to put all of these settings in a custom document class, or something similar, so that when I create new .tex files, I can simply say, \documentclass{custom_article}, instead of having to copy the same file to a new folder every time and then reference it?

  • Welcome to TeX.sx! Your question was migrated here from Stack Overflow. Please register on this site, too, and make sure that both accounts are associated with each other (by using the same OpenID), otherwise you won't be able to comment on or accept answers or edit your question.
    – Werner
    Commented Sep 28, 2012 at 14:24

1 Answer 1


If you want to create your own class, have a look at Rolling your own Document Class.

You can also find more detailed answers for these similar questions:

Not the answer you're looking for? Browse other questions tagged .