URL latex linebreak

Ljdawson picture Ljdawson · Apr 14, 2010 · Viewed 80.3k times · Source

When a URL is over a line and goes onto a second line, the hyperlink only uses the first line. Is there a way to get around this and yet still have the URL on multiple lines?

Answer

Peter picture Peter · Apr 14, 2010

You should use the url package:

\usepackage{url}
...
\url{http://long.url.com/...     .../stuff}

and it will break it for you at an appropriate place.