This question is very brief: how to be able to use the number sign (#) in the URL of an underlined href?
\documentclass{article}
\usepackage{hyperref}
\begin{document}
1 (without \#, link, underlined) = \underline{\href{http://the-best-URL-in-the-world_without-a-number-sign}{URL without number sign}}
% Un-comment the line below to see the error
2 (with \#, link, underlined) = % \underline{\href{http://the-best-URL-in-the-world_with-a-number-sign-#}{URL with a number sign}}
% For reference, the following works fine
3 (with \#, link, not underlined) = \href{http://the-best-URL-in-the-world_with-a-number-sign-#}{URL with a number sign}
\end{document}
Un-comment where indicated to see the compilation error.
P.S.: This question may or may not be similar to How to include a # sign in a url using the \endnotes package.

