Slugify Text

Generate URL-safe slugs from any text. Handles accents, Unicode, stop words, custom separators, length limits. Free, in-browser.

What this does

Generates URL-safe slugs from any input text — what you’d put in https://example.com/blog/<slug> or as an HTML id.

The pipeline:

  1. Unicode-normalize (NFKD) and strip combining diacritics so ée, ñn, üu.
  2. Map special characters that NFKD misses — ßss, ØO, ÆAE, ÞTH, ŒOE, ŁL.
  3. Lowercase (toggleable).
  4. Strip English stop words (toggleable, off by default — useful for shorter SEO slugs).
  5. Replace any non-alphanumeric character with the separator (default -).
  6. Collapse runs of separators to a single separator.
  7. Trim leading/trailing separators.
  8. Truncate to your max length, breaking on a separator.

Result: a string that’s safe to drop into a URL, an HTML id, a filename, an S3 key, a Kubernetes resource name, a database slug column.

Examples

InputOutput
Hello Worldhello-world
10 Best Coffee Shops in São Paulo!10-best-coffee-shops-in-sao-paulo
What's New in TypeScript 5.7?whats-new-in-typescript-5-7
Café — résumé naïvecafe-resume-naive
<script>alert(1)</script>script-alert-1-script

Why “URL-safe” matters

URLs are technically allowed to contain a lot of characters (RFC 3986 reserves :/?#[]@!$&'()*+,;=). In practice:

  • Anything outside [A-Za-z0-9-._~] should be percent-encoded. A URL with raw é becomes caf%C3%A9 in transit. Most browsers display it cleanly, but copy-paste flow, email clients, log aggregators, and some legacy systems mangle it.
  • Spaces become %20 or + depending on the encoder. Both look ugly in shareable URLs.
  • Slashes split the path and break routing. Even URL-encoded %2F is sometimes blocked or normalized away by web servers.

The safe set is a-z, 0-9, and one separator. Hyphen is conventional for URL slugs (Google states they prefer hyphens to underscores for readability). Underscore is conventional for filenames. Pick based on context.

Common use cases

  • Blog post titles → URLs. “Why I Stopped Using AWS” → /why-i-stopped-using-aws/. Stable, shareable, SEO-friendly.
  • User input → file names. A user uploads “My Résumé Final (v3).pdf”; you store it as my-resume-final-v3.pdf. Avoids encoding bugs across S3, Linux, Windows.
  • Heading anchors. Markdown’s # Section Title#section-title anchor. Same algorithm.
  • Kubernetes / Docker resource names. These have stricter rules (DNS-1123 subdomain: lowercase, max 63 chars, must not start/end with -). The defaults here match.
  • Search engine optimization. A keyword-rich slug ranks better than a numeric ID. /blog/12345/ is worse than /blog/why-i-stopped-using-aws/.

Stop word stripping — when to use

Off by default, because removing words can change meaning. With it on:

  • The Best of 2026best-2026 (shorter, more keyword-dense)
  • A Tale of Two Citiestale-two-cities (loses some context)
  • How to Win at AWSwin-aws (loses the “how-to” intent — bad for SEO)

Use stop-word stripping when slug length is the constraint. Skip it when the slug should match natural-language search intent.

What this does NOT do

  • Does not transliterate non-Latin scripts. 北京 stays 北京 (and gets replaced with separator, producing an empty slug). Use a transliteration library (unidecode, iconv) for CJK, Cyrillic, Arabic, Hindi.
  • Does not preserve uniqueness. If you slugify two different titles to the same slug, you get a collision. Add a numeric suffix or a short hash in your application code.
  • Does not check against existing slugs. That’s an application-layer concern — query your database before saving.

Privacy

Runs entirely in your browser.

Explore More Free Tools

🔧

Aspect Ratio Calculator

Calculate width, height, or ratio. Solve any one from the other two. 16:9, 4:3, 21:9, 9:16, 1:1, custom. Free, runs in your browser.

🔧

BPM to Milliseconds Calculator

Convert BPM to delay times in milliseconds. Whole, half, quarter, 1/8, 1/16, 1/32 notes plus dotted and triplet variants. Free tempo-sync calculator for producers.

🔧

Chmod Calculator

Convert chmod permissions between octal (e.g. 755) and symbolic (rwxr-xr-x) form. Toggle read/write/execute checkboxes for owner, group, and other. Free, runs in your browser.

🔧

Color Contrast Checker

Check color contrast for WCAG AA and AAA compliance. Live preview, hex and rgb support, instant pass/fail across 5 levels. Free, in-browser.

🔧

Cron Expression Explainer

Paste a cron expression, get a plain-English explanation plus the next 5 run times. Handles macros (@daily, @hourly), ranges, and steps. Free, in-browser.

🔧

CSV to Markdown Table

Paste CSV (or TSV), get a clean GitHub-flavored Markdown table. Auto column alignment, header detection, custom delimiters. Free, in-browser.

🔧

Cubic Bezier Generator

Visual editor for CSS cubic-bezier() easing curves. Drag the control handles, see the live animation, copy the CSS. Free, in-browser.

🔧

Env to JSON Converter

Convert .env files to JSON instantly. Handles quoted values, comments, escape sequences, and type coercion. Free, runs in your browser, no signup.

🔧

HTML Entity Encoder & Decoder

Encode and decode HTML entities — minimal, named, numeric, or hex. Handles &amp;, &lt;, &gt;, accented characters, em dash, smart quotes. Free, browser-based.

🔧

HTTP Status Code Lookup

Searchable reference for every HTTP status code. 1xx, 2xx, 3xx, 4xx, 5xx, plus Cloudflare 5xx codes. Free, instant lookup, runs in your browser.

🔧

JSON Diff

Compare two JSON values semantically. Shows added, removed, and changed keys with the exact path. Free, runs in your browser.

🔧

JSON to Go Struct Generator

Convert JSON to idiomatic Go structs with json tags, time.Time detection, omitempty support. Free, in-browser.

🔧

JSON to TypeScript Interface Generator

Paste JSON, get TypeScript interfaces. Handles nested objects, arrays, unions, optional fields. No signup, runs in your browser.

🔧

Lorem Ipsum Generator

Generate placeholder text. Classic Lorem Ipsum, hipster, corporate, and dev variants. Words, sentences, paragraphs, lists. Free, in-browser.

🔧

Markdown to HTML Converter

Convert Markdown to HTML with live preview. Headings, lists, code blocks, links, images, blockquotes. Free, in-browser.

🔧

Number Base Converter

Convert numbers between binary, octal, decimal, hex, and any base from 2 to 36. BigInt-safe for large values. Free, in-browser.

🔧

Text Case Converter

Convert text to camelCase, snake_case, kebab-case, PascalCase, CONSTANT_CASE, Title Case, and 7 more. Free, instant, in-browser.

🔧

YAML Validator

Validate YAML syntax, find duplicate keys, indentation issues, tabs in indent, and trailing whitespace. JSON preview included.

🔧

Cron Expression Generator

Generate and validate cron expressions with a visual builder. See next execution times, human-readable descriptions, and common presets. Free online crontab generator for developers.

🔧

JWT Decoder

Decode and inspect JWT tokens instantly. View header, payload, and signature. Check expiration, issuer, and claims. Free online JWT decoder — no data sent to any server.

🔧

Regex Tester

Test regular expressions with real-time matching and highlighting. Supports JavaScript regex flags (g, i, m, s). See match groups, captures, and indices. Free online regex tester.

🔧

Unix Timestamp Converter

Convert Unix timestamps to human-readable dates and vice versa. Supports seconds and milliseconds. Shows current epoch time live. Free online tool for developers.

🔧

UUID Generator

Generate random UUIDs (v4), time-based UUIDs (v7), and ULIDs instantly. Bulk generate up to 100 at once. Free online UUID generator for developers — no signup required.

🔧

Base64 Encoder & Decoder

Encode text to Base64 or decode Base64 back to plain text instantly. Free online Base64 converter with file support and batch processing. No registration required.

🎨

Color Palette Generator

Generate beautiful color palettes instantly. Create complementary, analogous, triadic, and monochromatic color schemes for web design, branding, and creative projects.

📝

JSON Formatter & Validator

Format, validate, and beautify JSON data instantly with our free online JSON formatter. Supports minification, syntax highlighting, and error detection. No registration required.

🔧

JSON to YAML Converter

Convert JSON to YAML and YAML to JSON instantly with our free online converter. Supports validation, formatting, and syntax highlighting. No registration required.

🔑

Password Generator

Generate strong, secure passwords instantly with our free password generator. Customize length, character types, and complexity. No registration required, privacy-focused.

📊

Percentage Calculator

Calculate percentages, percentage increases/decreases, and compare values instantly. Free online percentage calculator with multiple calculation types and detailed results.

🔧

SEO Meta Tag Generator

Generate SEO-optimized meta tags instantly. Create title tags, meta descriptions, Open Graph tags, and Twitter Cards for better search engine visibility.

🔧

Subnet Calculator

Plan IPv4 subnets visually. Enter a CIDR block, split it, see network/broadcast/host counts. Free, runs in your browser.

🔧

Tools Sitemap

Complete list of all free developer tools available on Ataiva. Find password generators, JSON formatters, converters, and more utilities for developers.

📏

Unit Converter

Convert between various units such as length, weight, temperature, and more.

📄

Word Counter & Text Analyzer

Count words, characters, sentences, and paragraphs instantly. Analyze readability, text complexity, and writing style with our text analyzer.