Hyperlink Generator
Generate an HTML hyperlink (anchor tag) with the exact attributes you need. Set the URL, link text, target, and rel attributes, then copy the code.
Recommended Settings
Pro Tips
- •Adding rel="noopener noreferrer" to links that open in a new tab prevents the new page from being able to access or manipulate your original page via window.opener
- •rel="nofollow" tells search engines not to pass ranking credit through the link - commonly used for sponsored links, user-generated content, or untrusted sources
- •The title attribute shows a tooltip on hover, which can help with accessibility and give visitors more context before clicking
- •Opening links in a new tab (_blank) can be useful for external references, but overusing it can be a frustrating experience for visitors
Most Popular
Most users generate a same-tab link, adding noopener noreferrer only when opening links in a new tab
When to Use This Tool
Generate properly formatted link HTML to paste into a page's source code.
Create hyperlink markup for use in HTML email templates.
Get the exact HTML for a link when a content management system's editor doesn't expose the attribute you need.
See how different combinations of target, rel, and title attributes affect a link's markup.
How It Works
Take the URL, link text, and any optional attributes you specify
Assemble them into a properly formatted HTML anchor (<a>) tag
Automatically add recommended security attributes like noopener and noreferrer when the link opens in a new tab
100% Private
Files never leave your device. All processing happens locally in your browser.
Lightning Fast
Powered by Client-side HTML generation for optimal performance on modern browsers.
Open Source
Built with verified, open-source libraries. Fully transparent.
Frequently Asked Questions
Why should I add noopener and noreferrer to new-tab links?
Without these attributes, a page opened in a new tab via target="_blank" can access your original page through JavaScript's window.opener property, which is both a minor security risk and a performance concern. Adding rel="noopener noreferrer" prevents this.
What does rel="nofollow" do?
It's a hint to search engines not to pass ranking authority through that link. It's commonly used for sponsored content, advertisements, or links to sources you don't want to vouch for.
Is my data sent to a server?
No. The HTML is generated entirely locally in your browser using JavaScript. Nothing you enter is transmitted anywhere.
Should I always open external links in a new tab?
It depends on your site's user experience goals. Many accessibility and UX guidelines recommend letting users control this themselves (for example, via middle-click or right-click) rather than forcing every external link into a new tab.
What's the difference between title and the link text?
The link text is what's visibly displayed and clickable. The title attribute is supplementary text that appears as a tooltip when hovering over the link - it doesn't replace the visible text.