How to Wrap Long DOI Hyperlinks Across Lines in Word
Question details
The user needs a way to force long DOI URLs to wrap across multiple lines in a Word document without breaking the clickable link destination.

- Product
- Word
- Device & OS
- not provided
- Scenario
- Formatting reference lists or bibliographies containing long DOI URLs.
- Observed behavior
- Long hyperlinks without spaces are moved entirely to the next line, creating large, unwanted blank spaces in the preceding text.
Before adjusting your hyperlinks, ensure that your document's paragraph alignment settings are finalized, as changing between left-aligned and justified text can significantly alter how long text strings wrap.
Insert a Space in the Displayed Hyperlink Text
Manually add a space in the hyperlink's display text to allow the word processor to break the line naturally.
By default, long strings of text without spaces are treated as a single word. Adding a space into the visible text gives the program a point at which to break the text and wrap it to the next line.
Right-click the problematic DOI hyperlink in your document and select 'Edit Hyperlink' from the context menu.
In the 'Text to display' box at the top of the dialog, place your cursor right before a forward slash (/) within the URL.
Press the spacebar to add a single space, then click 'OK' to apply the changes.

Reduce the Font Size of the Hyperlink Style
Decrease the text size of all hyperlinks in the document to fit longer URLs more comfortably on a single line.
Easily Manage Hyperlinks and References with WPS Writer
WPS Writer offers an intuitive interface for editing hyperlinks and formatting academic references. You can seamlessly adjust text wrapping, customize styles, and create professional documents without formatting frustrations.
- 1. Open your document: Launch WPS Writer and open your document containing the reference list.
- 2. Edit the hyperlink: Right-click the long DOI link and click 'Edit Hyperlink'.
- 3. Adjust display text: Add a space before a slash in the 'Text to display' field, and click 'OK'.
- 4. Customize styles universally: Use the Home tab to quickly adjust alignment or modify the global Hyperlink style if needed.

Frequently Asked Questions
Does adding a space to the hyperlink text break the DOI link?
No, adding a space in the 'Text to display' field only changes the visible text on the page. The actual 'Address' or URL destination field remains unaffected, so the link will still work correctly.
Can I use a zero-width space to wrap URLs?
Yes, inserting a zero-width space (Unicode 200B) allows the URL to wrap without displaying an actual blank space character. This maintains the exact visual formatting of the DOI while solving the text wrapping issue.
Why does my word processor automatically move my long links to the next line?
Word processors generally keep unbroken strings of characters together. If a URL has no spaces, it is treated as a single long word. If it doesn't fit on the current line, the entire string is pushed to the next line.
How do I fix awkward spacing in justified text with long URLs?
Justified text forces words to stretch across the page width. For reference lists with long URLs, it is highly recommended to change the paragraph alignment to Left-Aligned. This prevents large, irregular blank spaces between words.




