URL 编码解码
把文本转换为 URL percent encoding,或把编码内容还原为可读文本。
Loading tool…
浏览器内运行这个工具能做什么
在浏览器中对 URL 参数、路径片段和查询值进行编码或解码,适合链接调试和参数整理。
它能帮助你确认参数在复制、拼接和跳转过程中是否被正确转义。
这个工具可以完成什么
When passing a redirect URL as a query parameter (?return=https://example.com/path?x=1), the inner URL must be encoded so its ?x=1 doesn't get parsed as part of the outer URL. Use component-level encoding.
Spaces, accented characters, and emoji aren't valid in query strings as-is. Encode them to percent-encoded form (e.g., space becomes %20) so the URL survives every HTTP client, proxy, and server log.
When a value has been encoded twice, %20 becomes %2520. If a decoded URL still contains %25 patterns, decode it once more — double-encoding is a common bug across redirect chains and template engines.
依赖结果前需要检查什么
- Performance and maximum practical input size depend on browser memory, device speed, and the structure of the input.
- Review the generated result before replacing or publishing an original file.
如何使用
- 1
粘贴原始文本或已经编码的 URL 片段。
- 2
查看编码后和解码后的结果。
- 3
复制需要的版本,再放入链接、脚本或文档中。
使用场景
检查回调地址、搜索词、UTM 内容或嵌套 URL 是否被正确编码。
为 API 文档或排障记录提供可读参数和可复制编码值。
使用技巧
如果文本已经包含 %E4 这类片段,再次编码会改变含义,复制前要确认状态。
完整 URL 中的 ?、&、= 有结构意义,通常只需要编码具体参数值。
常见问题
空格会编码成什么?
在标准 percent encoding 中通常会编码为 %20,某些表单场景可能使用加号。
可以解码完整 URL 吗?
可以,但如果只想处理参数值,建议单独复制参数值进行解码。
输入内容会提交给 TOOLGRID 处理接口吗?
工具代码会在浏览器中处理所选文件和输入内容,不会将其提交给 TOOLGRID 的处理接口。浏览器本地处理不构成全面安全或离线保证。
下一步常用工具
如果还需要校验、转换或复用结果,可以继续打开相近的浏览器本地工具。