Skip to content
POST AI agent ready /v1/text/slugify

Slugify API - Free URL Slug Generator

Transforms any text into a URL-friendly slug by lowercasing, replacing spaces with hyphens, transliterating accented characters, and removing special symbols. The output is safe for URLs, file names, and database identifiers.

Parameters

stringrequired

The text to convert into a slug.

Code examples

curl -X POST https://api.botoi.com/v1/text/slugify \
  -H "Content-Type: application/json" \
  -d '{"text":"How to Build REST APIs in 2026"}'

When to use this API

Generate SEO-friendly URLs for blog posts

Convert article titles into clean URL slugs automatically when users create new content in your CMS.

Create safe file names from user input

Slugify uploaded file names to remove spaces and special characters before storing them on disk or in object storage.

Frequently asked questions

How are accented characters handled?
Accented characters are transliterated to their ASCII equivalents. For example, "cafe" becomes "cafe" and "uber" becomes "uber".
What characters are allowed in the output slug?
The output contains only lowercase letters (a-z), digits (0-9), and hyphens. All other characters are removed.
Are consecutive hyphens collapsed?
Yes. Multiple consecutive hyphens are collapsed into a single hyphen, and leading or trailing hyphens are removed.
Does this handle CJK (Chinese, Japanese, Korean) text?
CJK characters without direct ASCII transliterations are removed. For CJK-heavy content, consider keeping the original characters in your URL scheme.

Get your API key

Free tier includes 5 requests per minute with no credit card required. Upgrade for higher limits.