Integration guide
Add ONNO to your website.
Let external links on your website go through ONNO. Add the code below, then choose which domains should keep their original links.
Add the installation code
Copy this code before your page’s closing </body> tag. Replace the examples in excludeDomains with the domains you want to leave unchanged.
<script>
window.ONNO = {
excludeDomains: ['example.com', 'trusted.example.org']
};
</script>
<script defer referrerpolicy="no-referrer" src="https://onno.to/assets/onno-direct.v1.0.0.js"></script>
Version 1.0.0. The download is identical to the hosted script; you can host it on your own site.
Choose links to leave unchanged
Adding example.com keeps links to example.com and blog.example.com unchanged. It does not exclude notexample.com or example.com.evil.test.
Links within the same hostname, page anchors, ONNO links, downloads, email and telephone links stay unchanged. To skip a different subdomain of your site, add it to your list.
<a href="https://example.net/article" data-onno-skip>Unwrapped link</a>
Add data-onno-skip to a single link to leave it unchanged.
Your exclusion list means a link does not go through ONNO. ONNO’s auto-redirect list is different: those links still show a destination page, then continue after 2 seconds. Auto-redirect domains
Advanced: Direct formats and manual HTML
The script preserves target and rel, and adds noreferrer and noopener to links routed through ONNO.
Dynamic links are supported. If the script fails to load, the original links remain usable. No cookies, browser storage or analytics are added.
Simple URLs use the complete raw query, without splitting parameters or decoding again. Do not append ONNO options to the link.
https://onno.to/?https://example.com/path?a=1&a=2+3&empty=
URLs with a # fragment, Unicode or characters that a browser would rewrite use the compatible to= format. The homepage and this script choose the format for you, keeping the complete destination.
<a href="https://onno.to/?to=https%3A%2F%2Fexample.com%2Farticle%23section" rel="noreferrer noopener">Open link</a>
Existing to= Direct links and /s/ short links remain supported. New short links use https://onno.to/{code}.
No public creation API or external administration API is available.