Q:

Include a package in one chapter only

I have this package that removes the header from the pages        
 \fancypagestyle{noheadrule}{  \fancyhf{}
    \renewcommand{\headrulewidth}{0pt}  \fancyhead[LE,RO]{\thepage} }
    \pagestyle{noheadrule}

It works like a charm but i only want to use it in one chapter but it removes all the headers from all the pages of the project 

A:

It is not possible to include a package for one chapter and 'unload' it for another part of the document. 
However, it's possible to limit the effects what a chapter does, depending on the chapter. 
Explicitly define two different pagestyles, one for the particular chapter and another one, that restores the settings (or changes them to something other!)
\documentclass{book}

\usepackage{blindtext}

\usepackage{fancyhdr}

\fancypagestyle{headrule}{%
  \renewcommand{\headrulewidth}{2pt}  
  \fancyhead[CE]{foo}
  \fancyhead[LE,RO]{\thepage} 
}

\fancypagestyle{noheadrule}{%
  \fancyhf{}
  \renewcommand{\headrulewidth}{0pt}  
  \fancyhead[LE,RO]{\thepage} 
}

\begin{document}
\pagestyle{noheadrule}
\chapter{The one with no headrule}
\blindtext[15]

\clearpage
\pagestyle{headrule}
\chapter{The fancy one!}
\blindtext[15]

\end{document}

