Skip to content

About NOS.RE Url Shortener


NOS.RE is a simple URL shortener focused on the nostr community.

It is free to use and is donation supported like all services.

Browser Bookmarklet

Drag this link to your browser link bar to allow for shortneing from site wish to shorten:
NOS.RE Popup


NOS.RE uses recaptcha, DNS Spam Blacklists, rate-limiting, link active validation, and many other security measures to prevent Spam and other potential issues. If you encounter any issues please email us:


You need to send parameters to either via GET or POST
(remember to URL-encode parameters if via GET). These parameters are:

  • The requested action: "shorturl" (get short URL for a link), "expand" (get long URL of a shorturl), "url-stats" (get stats about one short URL), "stats" (get stats about your links) or "db-stats" (get global link and click count)
  • With action = "shorturl" :
    • the url to shorten
    • optional keyword and title for custom short URLs
    • output format: either "jsonp", "json", "xml" or "simple"
  • With action = "expand" :
    • the shorturl to expand (can be either 'abc' or '')
    • output format: either "jsonp", "json", "xml" or "simple"

Sample Requests

Example of a GET request with Javascript (using jQuery) to shorten a URL

var api_url  = '';
var response = $.get( api_url, {
    action:   "shorturl",
    format:   "json",
    url:      ""
    // callback function that will deal with the server response
    function( data) {
        // now do something with the data, for instance show new short URL:

Example of a POST request with PHP to expand a short URL

$api_url =  '';

// Init the CURL session
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $api_url);
curl_setopt($ch, CURLOPT_HEADER, 0);            // No header in the result
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); // Return, do not echo result
curl_setopt($ch, CURLOPT_POST, 1);              // This is a POST request
curl_setopt($ch, CURLOPT_POSTFIELDS, array(     // Data to POST
        'shorturl' => 'lay',
        'format'   => 'json',
        'action'   => 'expand',

// Fetch and return content
$data = curl_exec($ch);

// Do something with the result. Here, we echo the long URL
$data = json_decode( $data );
echo $data->longurl;

API Requests are rate-limited so if run into any issues please DM us: npub1hweyj43tg2ddgtkrgnj55cvg3d7qfckxppx6kyuk83puqkkzqhcqahyfue
NOS.RE on nostr