Welcome to Free URL Locker!

Developer API Documentation

You can use our API to generate shortened links seamlessly within your own applications, scripts, or systems. Below are the supported parameters and endpoints.

Basic URL Shortening

Endpoint URL:

GET https://lockmyurl.com/api.php?url=TARGET_URL
  • TARGET_URL Must begin with http:// or https://
URL with Custom Alias

Endpoint URL:

GET https://lockmyurl.com/api.php?url=TARGET_URL&cust=CUSTOM_ALIAS
  • CUSTOM_ALIAS Your custom slug (only letters, numbers, dash, and underscore allowed).
Password Protected URL

Endpoint URL:

GET https://lockmyurl.com/api.php?url=TARGET_URL&pass=PASSWORD
JSON Response Format

Success Response:

{
  "error": 0,
  "shorturl": "https://lockmyurl.com/myAlias"
}

Error Response:

{
  "error": "Invalid URL provided."
}