URL latex linebreak

Solution 1:

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.

Solution 2:

I suggest using package:

\usepackage{xurl}

This works fine for me on overleaf.

Example:

\url{https://www.tudelft.nl/ewi/over-de-faculteit/afdelingen/intelligent-systems/pattern-recognition-bioinformatics/pattern-recognition-laboratory/data-and-software/dd-tools/}

Solution 3:

At the preamble, just put \usepackage{breakurl} somewhere after \usepackage{hyperref}. The \burl command is defined and, by default, the package also turns the \url command into a synonym of \burl.

Solution 4:

Do it the following way. You are good to go!

\begin{document}
\sloppy