The nameref works in the appendix also (as shown in MWE of this answer). Hence without a complete MWE, we won't be able to help.
However, a better idea will be to use the package cleveref.
\documentclass{article}
\usepackage{lipsum}
\usepackage{hyperref}
\usepackage{cleveref}
\begin{document}
\section{One}\label{sec:one}
\lipsum[1]
\appendix
\label{appendix}
\section{Background}
\label{sec:background}
\lipsum[2]
From sections~\nameref{sec:one} and~\nameref{sec:background}, we get the idea of using \verb|nameref| from \verb|hyperref|!
From sections~\ref{sec:one} and~\ref{sec:background}, do we get the idea?
From \cref{sec:one} and~\cref{sec:background}, do we get the idea of using the package \verb|cleveref|?
\end{document}

For details, refer to the package documentation (texdoc cleveref from command prompt)
\namerefto produce when cross-referencing a section contained in the document's appendix, i.e., located after the\appendixcommand? – Mico Oct 13 '12 at 12:12\appendixonly reset the counter and change the numbering format toAlpha. – Sigur Oct 13 '12 at 13:36