[Tex/LaTex] bibtex large spacing

bibliographieshorizontal alignmentline-breakingurls

I couldn't find a solution to my problem searching. Apologies if it has been asked before.

My problem is: on a few of my bibliography entries, there are massive spaces in the text to pad out the lines, how can I avoid this to improve the appearance?

enter image description here

Best Answer

...
\usepackage{ragged2e}
\edef\UrlBreaks{\do\-\UrlBreaks}% after loading url or hyperref
...
...
\begingroup
\RaggedRight
\bibliographystyle{...}
\bibliography{...}
\endgroup