在线免费文字转Slug
将文字转换为URL友好的小写slug。
Who uses the 文字转Slug?
- 博主在发布前根据文章标题创建 SEO 友好的永久链接。
- 开发者根据用户输入的字符串生成唯一的文件名或数据库键。
- CMS 管理员在迁移内容中标准化 URL slug 格式。
How the 文字转Slug works
在输入字段中输入或粘贴您的标题或短语。
随着您的输入,slug 会自动生成。
选择分隔符(连字符或下划线),并切换「小写」(默认开启)。
一键复制 slug,用于 URL、文件名或 CMS 文章 slug。
Tips & tricks
- 没有停用词删除选项——像「the」和「a」这样的单词会原封不动地保留在 slug 中。如果您想为了更短、更聚焦关键词的 URL 而删除它们,请先编辑输入文本。
- 重音字符会自动转写为其 ASCII 等效形式(é→e,ü→u)——这在每次转换时都会发生,不是需要开启的切换开关。
- 分隔符选择(连字符或下划线)和小写切换开关是仅有的两个自定义选项——转换的其他方面都是固定的。
Frequently Asked Questions
什么是 URL slug?
slug 是 URL 中人类可读的部分,用于标识特定页面。例如,在 https://example.com/blog/my-awesome-post/ 中,slug 是「my-awesome-post」。slug 仅使用小写字母、数字和连字符。
此工具是否会自动删除「the」「a」「is」等停用词?
不会——没有停用词删除功能。您输入的每个单词都会保留在 slug 中;如果您希望为 SEO 删除停用词,需要在转换前自行编辑输入文本。
URL slug 中不允许使用哪些字符?
避免使用空格(改用连字符)、特殊字符(#、%、&、?、/)、大写字母和重音字符(é、ü、ñ)。此工具会自动删除特殊字符并转写重音字符。
URL slug 中应该使用连字符还是下划线?
使用连字符。谷歌将连字符视为单词分隔符(my-post = 「my」+「post」)。下划线被视为单词连接符(my_post = 「mypost」),这可能会损害搜索中的关键词识别。此工具允许您通过单选按钮选择任意一种。
我可以转换带重音字符的非英语标题吗?
可以。该工具在生成 slug 之前,会使用 Unicode 规范化将重音字符转写为其 ASCII 等效形式(é→e,ü→u,ñ→n)。这确保了纯 ASCII 的干净 URL。
Is my data safe when using the 文字转Slug?
Completely safe. The 文字转Slug processes everything locally in your browser. No input data, results, or usage information is ever transmitted to or stored on any server.
Is there a character or word limit for the 文字转Slug?
The 文字转Slug has no hard character limit — it processes text as large as your browser can handle, typically hundreds of thousands of characters. Very large inputs may be slower depending on your device.
Can the 文字转Slug process text in other languages?
Yes. The 文字转Slug handles all Unicode text correctly, including accented characters, CJK characters, Arabic, Cyrillic, and emoji. It works with any language that your browser renders, with no additional setup or language packs required.