Skip to content

OpenShort.link

Branded short links on your own domain, routed by country or device, with QR codes and click analytics

OpenShort.link homepage with Deploy to Cloudflare and View on GitHub buttons

OpenShort.link is a self-hosted URL shortener whose per-link rules send visitors to different destinations by city, country, operating system or device type. It includes team roles with TOTP two-factor login, CSV import and a REST API.

OpenShort.link answers every redirect from a Worker, with the 301, 302, 307 or 308 code you choose for each link. Links, users and settings live in D1, and KV caches redirect data. Routing rules are checked in order: city, country (up to 10 per link), operating system (Android or iOS), device type, then the default URL. A scheduled job checks destination URLs every six hours and flags dead links. Clicks are written to Workers Analytics Engine and broken down by country, device, browser, operating system, referrer, UTM parameters and custom parameters. Each link can carry tags, categories and its own Open Graph and Twitter Card tags, which the dashboard can prefill from the destination page. QR codes are generated and tracked per link. CSV import with column mapping helps when moving from another shortener, and bulk edits change many links at once. Team members get owner, admin, editor or viewer roles. Passwords are hashed with PBKDF2 at 100,000 iterations, sessions use HttpOnly cookies, and users can turn on TOTP. API keys cover the REST API, whose documentation appears inside each installation's dashboard. The Deploy to Cloudflare button forks the repository, creates the D1 database and KV namespace, and applies the migrations. It also asks for SETUP_TOKEN, your account ID and an API token with Account Analytics Read permission, which the dashboard uses to read click data.

Built for: Marketers, bloggers, affiliate publishers and small businesses who want branded short links and click analytics on their own domain.

What you can use it for

  • Shorten and track outbound links from a blog or social posts
  • Send visitors to different pages by country or device
  • Track campaign clicks with UTM and referrer breakdowns
  • Put trackable QR codes on print materials
  • Manage affiliate links as a team with role-based access

Deploy

  • One-click · main path

    Branch main

  • CLI

    Branch main

    Paste the D1 database_id and the KV id and preview_id into wrangler.toml before running npm run deploy.

    npm install
    npx wrangler login
    npx wrangler d1 create openshortlink-db
    npx wrangler kv namespace create CACHE
    npx wrangler kv namespace create CACHE --preview
    npx wrangler secret put SETUP_TOKEN
    npx wrangler secret put CLOUDFLARE_ACCOUNT_ID
    npx wrangler secret put CLOUDFLARE_API_TOKEN
    npm run deploy

Create the API token with Account Analytics Read permission before using the button. After the deploy, add Worker routes for your domain, such as yourdomain.com/go/* and yourdomain.com/dashboard/*, then create the first admin at /dashboard/setup with SETUP_TOKEN.

What it needs to run

  • Analytics Engineopenshortlink-analytics
  • D1 databasesopenshortlink-db
  • KV namespacesCACHE

Good to know

There is no public sign-up, so an admin creates every user account. Worker routes on your domain must not clash with paths the existing site already uses. Under AGPL-3.0, anyone who runs a modified version as a network service must make its source available to that service's users. The project has one maintainer.

Cost on Cloudflare

Depends on usage

Every redirect is a Worker request, and Workers Free allows 100,000 requests per day. Free also includes 100,000 KV reads and 1,000 KV writes per day, a D1 allowance, and 100,000 Analytics Engine data points written per day. The app's two cron triggers count toward the five an account gets on Free. High-traffic link sets will need Workers Paid.

Source

The estimate is based on Cloudflare’s documented limits and the app’s configuration. What you pay depends on your usage and plan.

Where this comes from

An alternative to Bitly, Cuttly, Dub, Rebrandly, Short.io, T.LY, TinyURL.

Listing history

  • Oct 2, 2026 · OpenShort.link listed
  • shrtnr dashboard with 30-day click totals, a clicks-over-time chart, top countries, most clicked links and top domains

    Self-hosted URL shortener with a REST API, typed SDKs and an MCP server, on Workers, D1 and Cloudflare Access

    Deploy
    One-click
    License
    Apache-2.0
    GitHub stars
    30 stars
    Last commit