# urls.PathUnescape
> 返回给定字符串，并把所有百分号编码序列替换为对应的未转义字符。
- 官方英文原文：https://gohugo.io/functions/urls/pathunescape/
- 本页规范地址：https://hugozh.cn/functions/urls/pathunescape/
- 最近更新：2026-10-02
- 最后提交：912b1d3 chore(site): 添加 static/CNAME（hugozh.cn），供 GitHub Pages 等平台绑定自定义域名
- 签名：urls.PathUnescape INPUT
- 返回类型：string
- 站点：Hugo 中文文档（https://hugozh.cn/）· 社区维护的非官方中文翻译，如有出入以官方英文原文为准

---
**（0.153.0 新增）**

`urls.PathUnescape` 函数执行 [`urls.PathEscape`][] 的逆变换。

```go-html-template
{{ urls.PathUnescape "A%2Fb%2Fc%3Fd=%C3%A9&f=g+h" }} → A/b/c?d=é&f=g+h
```

用该函数解码 URL 路径中的单个片段。

[`urls.PathEscape`]: /functions/urls/pathescape/

